<html>
<META http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<head>
<title>Appendix A.&nbsp; Function Prototypes</title>
<link rel="STYLESHEET" type="text/css" href="images/style.css">
<link rel="STYLESHEET" type="text/css" href="images/docsafari.css">
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td><div STYLE="MARGIN-LEFT: 0.15in;"><a href="toc.html"><img src="images/team.gif" width="60" height="17" border="0" align="absmiddle"  alt="Team BBL"></a></div></td>
<td align="right"><div STYLE="MARGIN-LEFT: 0.15in;">
<a href=ch21lev1sec7.html><img src="images/prev.gif" width="60" height="17" border="0" align="absmiddle" alt="Previous Page"></a>
<a href=app02.html><img src="images/next.gif" width="60" height="17" border="0" align="absmiddle" alt="Next Page"></a>
</div></td></tr></table>
<br><table width="100%" border="0" cellspacing="0" cellpadding="0"><tr><td valign="top"><a name="app01"></a><h2 class="docAppendixTitle">Appendix A. Function Prototypes</h2>

<p class="docText"><a name="idd1e159549"></a><a name="idd1e159554"></a><a name="idd1e159557"></a><a name="idd1e159560"></a>This appendix contains the function prototypes for the standard ISO C, POSIX, and UNIX System functions described in the text. Often, we want to see only the arguments to a function (&quot;Which argument is the file pointer for <tt>fgets</tt>?&quot;) or only the return value (&quot;Does <tt>sprintf</tt> return a pointer or a count?&quot;). These prototypes also show which headers need to be included to obtain the definitions of any special constants and to obtain the ISO C function prototype to help detect any compile-time errors.</P>
<p class="docText">The page number reference for each function prototype appears to the right of the first header file listed for the function. The page number reference gives the page containing the prototype for the function. That page should be consulted for additional information on the function.</P>
<p class="docText">Some functions are supported by only a few of the platforms described in this text. In addition, some platforms support function flags that other platforms don't support. In these cases, we usually list the platforms for which support is provided. In a few cases, however, we list platforms that lack support.</p>
<P><table cellspacing="0" FRAME="void" RULES="none" cellpadding="5"><colgroup><col width="40"><col width="90"><col width="330"><col width="90"></colgroup><thead></thead><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>
<span class="docEmphStrong">abort</span> (void);
</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;stdlib.h&gt;</pre><br>
</P>
<p class="docText">This function never returns</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec17.html#inta01">340</a>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>
<span class="docEmphStrong">accept</span>(int<span class="docEmphItalicAlt">sockfd</span>, struct sockaddr *restrict <span class="docEmphItalicAlt">addr</span>,
       socklen_t *restrict <span class="docEmphItalicAlt">len</span>);</pre><br>

</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;sys/socket.h&gt;
</pre><br>
</p>
<p class="docText">Returns: file (socket) descriptor if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec4.html#inta02">563</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">access</span>(const char *<span class="docEmphItalicAlt">pathname</span>, int <span class="docEmphItalicAlt">mode</span>);
             &lt;unistd.h&gt;
             <span class="docEmphItalicAlt">mode</span>: R_OK, W_OK, X_OK, F_OK</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec7.html#inta03">95</a></P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>unsigned<br>int</pre><BR>
</p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">alarm</span>(unsigned int <span class="docEmphItalicAlt">seconds</span>);</pre><BR>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 or number of seconds until previously set alarm</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec10.html#inta04">313</a>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">asctime</span>(const struct tm *<span class="docEmphItalicAlt">tmptr</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><BR>
</p>
<p class="docText">Returns: pointer to null-terminated string</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec10.html#inta05">175</a>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">atexit</span>(void (*<span class="docEmphItalicAlt">func</span>)(void));</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, nonzero on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec3.html#inta06">182</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID12"></a><div class="v1"><a href="app01.html#PLID12">[View full width]</a></div><pre><span class="docEmphStrong">bind</span>(int <span class="docEmphItalicAlt">sockfd</span>, const struct sockaddr *<span class="docEmphItalicAlt">addr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> socklen_t <span class="docEmphItalicAlt">len</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta07">560</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">*calloc</span>(size_t <span class="docEmphItalicAlt">nobj</span>, size_t size);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</p><p class="docText">Returns: non-null pointer if OK, <tt>NULL</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec8.html#inta08">189</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>speed_t</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">cfgetispeed</span>(const struct termios *<span class="docEmphItalicAlt">termptr</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><BR>
</p><p class="docText">Returns: baud rate value</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec7.html#inta09">652</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>speed_t</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">cfgetospeed</span>(const struct termios *<span class="docEmphItalicAlt">termptr</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><br>
</p><p class="docText">Returns: baud rate value</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec7.html#inta09">652</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">cfsetispeed</span>(struct termios *<span class="docEmphItalicAlt">termptr</span>, speed_t <span class="docEmphItalicAlt">speed</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec7.html#inta09">652</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">cfsetospeed</span>(struct termios *<span class="docEmphItalicAlt">termptr</span>, speed_t <span class="docEmphItalicAlt">speed</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec7.html#inta09">652</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">chdir</span>(const char *<span class="docEmphItalicAlt">pathname</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec22.html#inta13">125</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">chmod</span>(const char *<span class="docEmphItalicAlt">pathname</span>, mode_t <span class="docEmphItalicAlt">mode</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/stat.h&gt;<span class="docEmphasis">mode</span>:
S_IS[UG]ID, S_ISVTX, S_I[RWX](USR|GRP|OTH)</pre><BR>
</p><p class="docText">Returns:
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec9.html#inta14">99</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">chown</span>(const char *<span class="docEmphItalicAlt">pathname</span>, uid_t <span class="docEmphItalicAlt">owner</span>, gid_t <span class="docEmphItalicAlt">group</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec11.html#inta15">102</a>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">clearerr</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta16">141</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">close</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec5.html#inta17">63</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">closedir</span>(DIR *<span class="docEmphItalicAlt">dp</span>);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;dirent.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec20.html#inta18">120</a></P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">closelog</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;syslog.h&gt;</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch13lev1sec4.html#inta293">430</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>unsigned<BR>char</pre><br>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">CMSG_DATA</span>(struct cmsghdr *<span class="docEmphItalicAlt">cp</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><br>
</p><p class="docText">Returns: pointer to data associated
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> with <tt>cmsghdr</tt> structure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec4.html#inta20">607</a></p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>struct<br>cmsghdr</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">CMSG_FIRSTHDR</span>(struct msghdr *<span class="docEmphItalicAlt">mp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</p><p class="docText">Returns: pointer to first <tt>cmsghdr</tt>
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> structure associated with the <tt>msghdr</tt><BR>structure, or
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <tt>NULL</tt> if none exists</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec4.html#inta20">607</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>unsigned<br>int</pre><BR>
</P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">CMSG_LEN</span>(unsigned int <span class="docEmphItalicAlt">nbytes</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><br>
</P><p class="docText">Returns: size to allocate for data
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> object <span class="docEmphItalicAlt">nbytes</span> large</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec4.html#inta20">607</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>struct<br>cmsghdr</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">CMSG_NXTHDR</span>(struct msghdr *<span class="docEmphItalicAlt">mp</span>, struct cmsghdr *<span class="docEmphasis">cp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer to next <tt>cmsghdr</tt>
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> structure associated with the <tt>msghdr</tt><br>structure
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> given the current <tt>cmsghdr</tt> structure, or <tt>NULL</tt> if
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> we're<BR>at the last one</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec4.html#inta20">607</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID50"></a><div class="v1"><a href="app01.html#PLID50">[View full width]</a></div><pre><span class="docEmphStrong">connect</span>(int <span class="docEmphItalicAlt">sockfd</span>, const struct sockaddr *<span class="docEmphItalicAlt">addr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> socklen_t <span class="docEmphItalicAlt">len</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta24">561</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">creat</span>(const char *<span class="docEmphItalicAlt">pathname</span>, mode_t <span class="docEmphItalicAlt">mode</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID53"></a><div class="v1"><a href="app01.html#PLID53">[View full width]</a></div><pre>&lt;fcntl.h&gt;<span class="docEmphasis">
mode</span>: S_IS[UG]ID, S_ISVTX, S_I[RWX]
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(USR|GRP|OTH)</pre><BR>
</P><p class="docText">Returns: file descriptor opened for
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> write-only if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec4.html#inta25">62</a></P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">ctermid</span>(char *<span class="docEmphItalicAlt">ptr</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P><p class="docText">Returns: pointer to name of controlling
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> terminal on success, pointer to<br>empty string on error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec9.html#inta26">654</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">*ctime</span>(const time_t *<span class="docEmphItalicAlt">calptr</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer to null-terminated string</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec10.html#inta05">175</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">dup</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: new file descriptor if OK, 1
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec12.html#inta28">76</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">dup2</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">filedes2</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: new file descriptor if OK, 1
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec12.html#inta28">76</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endgrent</span>(void);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;grp.h&gt;</pre><br>
</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec4.html#inta30">167</a>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endhostent</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta31">553</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endnetent</span>(void);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endprotoent</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta33">554</a></p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endpwent</span>(void);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pwd.h&gt;</pre><br>
</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec2.html#inta34">164</a></P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endservent</span>(void);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta35">555</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">endspent</span>(void);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;shadow.h&gt;</pre><br>
</P><p class="docText">Platforms: Linux 2.4.22, Solaris 9</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec3.html#inta36">166</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID76"></a><div class="v1"><a href="app01.html#PLID76">[View full width]</a></div><pre><span class="docEmphStrong">execl</span>(const char *<span class="docEmphItalicAlt">pathname</span>, const char *<span class="docEmphItalicAlt">arg0</span>, ... 
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">/* (char *) 0 */ );</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: 1 on error, no return on success</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec10.html#inta37">231</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID78"></a><div class="v1"><a href="app01.html#PLID78">[View full width]</a></div><pre><span class="docEmphStrong">execle</span>(const char *<span class="docEmphItalicAlt">pathname</span>, const char *<span class="docEmphItalicAlt">arg0</span>, ...
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> /* (char *) 0,
       char *const <span class="docEmphItalicAlt">envp</span>[] */ );</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 1 on error, no return on success</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec10.html#inta37">231</a></P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID80"></a><div class="v1"><a href="app01.html#PLID80">[View full width]</a></div><pre><span class="docEmphStrong">execlp</span>(const char *<span class="docEmphItalicAlt">filename</span>, const char *<span class="docEmphItalicAlt">arg0</span>, ...
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> /* (char *) 0 */ );</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: 1 on error, no return on success</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec10.html#inta37">231</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">execv</span>(const char *<span class="docEmphItalicAlt">pathname</span>, char *const <span class="docEmphItalicAlt">argv</span>[]);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">Returns: 1 on error, no return on success</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec10.html#inta37">231</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID84"></a><div class="v1"><a href="app01.html#PLID84">[View full width]</a></div><pre><span class="docEmphStrong">execve</span>(const char *<span class="docEmphItalicAlt">pathname</span>, char *const <span class="docEmphItalicAlt">argv</span>[],
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> char *const <span class="docEmphItalicAlt">envp</span>[]);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: 1 on error, no return on success</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec10.html#inta37">231</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">execvp</span>(const char *<span class="docEmphItalicAlt">filename</span>, char *const <span class="docEmphItalicAlt">argv</span>[]);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 1 on error, no return on success</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec10.html#inta37">231</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">_Exit</span>(int <span class="docEmphItalicAlt">status</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</P><p class="docText">This function never returns</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec3.html#inta43">180</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">_exit</span>(int <span class="docEmphItalicAlt">status</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">This function never returns</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec3.html#inta43">180</a></P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">exit</span>(int <span class="docEmphItalicAlt">status</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</P><p class="docText">This function never returns</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec3.html#inta43">180</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fattach</span>(int <span class="docEmphItalicAlt">filedes</span>, const char *<span class="docEmphItalicAlt">path</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stropts.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error<BR>Platforms: Linux 2.4.22, Solaris 9</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec2.html#inta46">589</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fchdir</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec22.html#inta13">125</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fchmod</span>(int <span class="docEmphItalicAlt">filedes</span>, mode_t <span class="docEmphItalicAlt">mode</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID99"></a><div class="v1"><a href="app01.html#PLID99">[View full width]</a></div><pre>&lt;sys/stat.h&gt;
<span class="docEmphasis">mode</span>: S_IS[UG]ID, S_ISVTX, S_I[RWX]
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(USR|GRP|OTH)</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec9.html#inta14">99</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fchown</span>(int <span class="docEmphItalicAlt">filedes</span>, uid_t <span class="docEmphItalicAlt">owner</span>, gid_t <span class="docEmphItalicAlt">group</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec11.html#inta15">102</a></p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fclose</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, <tt>EOF</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec5.html#inta50">139</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fcntl</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">cmd</span>, ... /* int <span class="docEmphItalicAlt">arg</span> */ );</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID105"></a><div class="v1"><a href="app01.html#PLID105">[View full width]</a></div><pre>&lt;fcntl.h&gt;
<span class="docEmphasis">cmd</span>: F_DUPFD, F_GETFD, F_SETFD, F_GETFL, F_SETFL,
     F_GETOWN, F_SETOWN, F_GETLK, F_SETLK,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> F_SETLKW</pre><br>
</p><p class="docText">Returns: depends on <span class="docEmphItalicAlt">cmd</span> if OK, 1 on error</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec14.html#inta51">78</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fdatasync</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error<br>Platforms
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">: Linux 2.4.22, Solaris 9</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec13.html#inta52">77</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">FD_CLR</span>(int <span class="docEmphItalicAlt">fd</span>, fd_set *<span class="docEmphItalicAlt">fdset</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/select.h&gt;</pre><BR>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec5.html#inta53">476</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fdetach</span>(const char *<span class="docEmphItalicAlt">path</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stropts.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error<br>Platforms: Linux 2.4.22, Solaris 9</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec2.html#inta54">590</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">FD_ISSET</span>(int <span class="docEmphItalicAlt">fd</span>, fd_set *<span class="docEmphItalicAlt">fdset</span>);</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/select.h&gt;</pre><br>
</P><p class="docText">Returns: nonzero if <span class="docEmphItalicAlt">fd</span> is in set, 0
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> otherwise</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec5.html#inta53">476</a></p></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>FILE</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">fdopen</span>(int <span class="docEmphItalicAlt">filedes</span>, const char *<span class="docEmphItalicAlt">type</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
<span class="docEmphItalicAlt">type</span>: "r", "w", "a", "r+", "w+", "a+",</pre><br>
</p>
<p class="docText">Returns: file pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec5.html#inta56">138</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">FD_SET</span>(int <span class="docEmphItalicAlt">fd</span>, fd_set *<span class="docEmphItalicAlt">fdset</span>);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/select.h&gt;</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec5.html#inta53">476</a></P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">FD_ZERO</span>(fd_set *<span class="docEmphItalicAlt">fdset</span>);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/select.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec5.html#inta53">476</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">feof</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P><p class="docText">Returns: nonzero (true) if end of file on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> stream, 0 (false) otherwise</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta16">141</a></P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ferror</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: nonzero (true) if error on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> stream, 0 (false) otherwise</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta16">141</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fflush</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, <tt>EOF</tt> on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec4.html#inta61">137</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fgetc</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: next character if OK, <tt>EOF</tt> on end
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> of file or error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta62">140</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fgetpos</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, fpos_t *restrict <span class="docEmphItalicAlt">pos</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, nonzero on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta63">148</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">fgets</span>(char *restrict <span class="docEmphItalicAlt">buf</span>, int <span class="docEmphItalicAlt">n</span>, FILE *restrict <span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: <tt>buf</tt> if OK, <tt>NULL</tt> on end of file
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> or error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec7.html#inta64">142</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fileno</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P><p class="docText">Returns: file descriptor associated with
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> the stream</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta65">153</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">flockfile</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta66">403</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>FILE</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID136"></a><div class="v1"><a href="app01.html#PLID136">[View full width]</a></div><pre>*<span class="docEmphStrong">fopen</span>(const char *restrict <span class="docEmphItalicAlt">pathname</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">type</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
<span class="docEmphItalicAlt">type</span>: "r", "w", "a", "r+", "w+", "a+",</pre><BR>
</P>
<p class="docText">Returns: file pointer if OK, <tt>NULL</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec5.html#inta56">138</a></P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fork</span>(void);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 0 in child, process ID of child
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> in parent, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec3.html#inta68">211</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>long</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fpathconf</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">name</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID141"></a><div class="v1"><a href="app01.html#PLID141">[View full width]</a></div><pre>&lt;unistd.h&gt;
<span class="docEmphasis">name</span>: _PC_ASYNC_IO, _PC_CHOWN_RESTRICTED,
      _PC_FILESIZEBITS, _PC_LINK_MAX, _PC_MAX_CANON,
      _PC_MAX_INPUT, _PC_NAME_MAX, _PC_NO_TRUNC,
      _PC_PATH_MAX, 'u'_PC_PIPE_BUF, _PC_PRIO_IO,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> _PC_SYNC_IO,
      _PC_SYMLINK_MAX, _PC_VDISABLE</pre><br>
</P><p class="docText">Returns:
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> corresponding value if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch02lev1sec5.html#inta175">41</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID142"></a><div class="v1"><a href="app01.html#PLID142">[View full width]</a></div><pre><span class="docEmphStrong">fprintf</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, const char *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">format</span>, ...);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P><p class="docText">Returns: number of characters output if
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> OK, negative value if output error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta70">149</a></P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fputc</span>(int <span class="docEmphItalicAlt">c</span>, FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P><p class="docText">Returns: <span class="docEmphasis">c</span> if OK, <tt>EOF</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta253">142</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fputs</span>(const char *restrict <span class="docEmphItalicAlt">str</span>, FILE *restrict <span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: non-negative value if OK, <tt>EOF</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec7.html#inta259">143</a></P></td></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>size_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID148"></a><div class="v1"><a href="app01.html#PLID148">[View full width]</a></div><pre><span class="docEmphStrong">fread</span>(void *restrict <span class="docEmphItalicAlt">ptr</span>, size_t <span class="docEmphItalicAlt">size</span>, size_t <span class="docEmphItalicAlt">nobj</span>
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">, FILE *restrict <span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: number of objects read</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec9.html#inta73">146</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">free</span>(void *<span class="docEmphItalicAlt">ptr</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><BR>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec8.html#inta08">189</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">freeaddrinfo</span>(struct addrinfo *<span class="docEmphItalicAlt">ai</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
&lt;netdb.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta75">555</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>FILE</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID154"></a><div class="v1"><a href="app01.html#PLID154">[View full width]</a></div><pre>*<span class="docEmphStrong">freopen</span>(const char *restrict <span class="docEmphItalicAlt">pathname</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">type</span>,
         FILE *restrict <span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;<span class="docEmphasis">type</span>: "r", "w", "a", "r+", "w+", "a+",</pre><BR>
</P>
<p class="docText">Returns: file pointer if OK, <tt>NULL</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec5.html#inta56">138</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID156"></a><div class="v1"><a href="app01.html#PLID156">[View full width]</a></div><pre><span class="docEmphStrong">fscanf</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, const char *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">format</span>, ...);</pre><BR>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: number of input items assigned,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <tt>EOF</tt> if input error or end of file<br>before any conversion</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a></p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fseek</span>(FILE *<span class="docEmphItalicAlt">fp</span>, long <span class="docEmphItalicAlt">offset</span>, int <span class="docEmphItalicAlt">whence</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
<span class="docEmphasis">whence</span>: SEEK_SET, SEEK_CUR, SEEK_END</pre><br>
</P><p class="docText">Returns: 0 if
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> OK, nonzero on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta272">147</a></P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fseeko</span>(FILE *<span class="docEmphItalicAlt">fp</span>, off_t <span class="docEmphItalicAlt">offset</span>, int <span class="docEmphItalicAlt">whence</span>);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
<span class="docEmphasis">whence</span>: SEEK_SET, SEEK_CUR, SEEK_END</pre><br>
</p><p class="docText">Returns: 0 if
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> OK, nonzero on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta79">148</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fsetpos</span>(FILE *<span class="docEmphItalicAlt">fp</span>, const fpos_t *<span class="docEmphItalicAlt">pos</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, nonzero on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta63">148</a></p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fstat</span>(int <span class="docEmphItalicAlt">filedes</span>, struct stat *<span class="docEmphItalicAlt">buf</span>);</pre><br>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/stat.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec2.html#inta81">87</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fsync</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec13.html#inta52">77</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>long</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ftell</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: current file position indicator
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> if OK, -1L on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta272">147</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>off_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ftello</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P><p class="docText">Returns: current file position indicator
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> if OK, <tt>(off_t)</tt>-<tt>1</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta79">148</a></P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>key_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ftok</span>(const char *<span class="docEmphItalicAlt">path</span>, int <span class="docEmphItalicAlt">id</span>);</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/ipc.h&gt;</pre><br>
</p><p class="docText">Returns: key if OK, <tt>(key_t)</tt>-1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec6.html#inta85">519</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ftruncate</span>(int <span class="docEmphItalicAlt">filedes</span>, off_t <span class="docEmphItalicAlt">length</span>);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec13.html#inta86">105</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ftrylockfile</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, nonzero if lock can't
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> be acquired</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta66">403</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">funlockfile</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta66">403</a></p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">fwide</span>(FILE *<span class="docEmphItalicAlt">fp</span>, int <span class="docEmphasis">mode</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
&lt;wchar.h&gt;</pre><BR>
</p>
<p class="docText">Returns: positive if stream is wide oriented, negative if stream is<BR>byte oriented, or 0 if stream has no orientation</p>
</td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec2.html#inta89">134</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>size_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID182"></a><div class="v1"><a href="app01.html#PLID182">[View full width]</a></div><pre><span class="docEmphStrong">fwrite</span>(const void *restrict <span class="docEmphItalicAlt">ptr</span>, size_t <span class="docEmphItalicAlt">size</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> size_t <span class="docEmphItalicAlt">nobj</span>,
       FILE *restrict <span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P><p class="docText">Returns: number of objects written</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec9.html#inta73">146</a></P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>const <BR>char</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">gai_strerror</span>(int <span class="docEmphItalicAlt">error</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</p><p class="docText">Returns: a pointer to a string describing
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> the error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta91">556</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID186"></a><div class="v1"><a href="app01.html#PLID186">[View full width]</a></div><pre><span class="docEmphStrong">getaddrinfo</span>(const char *restrict <span class="docEmphItalicAlt">host</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">service</span>,
            const struct addrinfo *restrict <span class="docEmphItalicAlt">hint</span>,
            struct addrinfo **restrict <span class="docEmphasis">res</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt; &lt;netdb.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, nonzero
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error code on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta35">555</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getc</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p><p class="docText">Returns: next character if OK, <tt>EOF</tt> on end
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> of file or error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta62">140</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getchar</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p><p class="docText">Returns: next character if OK, <tt>EOF</tt> on end
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> of file or error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta62">140</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getchar_unlocked</span>(void);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: the next character if OK, <tt>EOF</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> end of file or error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta66">403</a></p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getc_unlocked</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P><p class="docText">Returns: the next character if OK, <tt>EOF</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> end of file or error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta66">403</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getcwd</span>(char *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">size</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: <span class="docEmphasis">buf</span> if OK, <tt>NULL</tt> on error</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec22.html#inta97">126</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>gid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getegid</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: effective group ID of calling
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> process</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec2.html#inta98">210</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getenv</span>(const char *<span class="docEmphItalicAlt">name</span>);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer to <span class="docEmphasis">value</span> associated
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> with <span class="docEmphasis">name</span>, <tt>NULL</tt> if not found</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec9.html#inta99">192</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>uid_t</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">geteuid</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: effective user ID of calling
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> process</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec2.html#inta98">210</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>gid_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getgid</span>(void);</pre><BR>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: real group ID of calling process</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec2.html#inta98">210</a></p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structgroup</pre><BR>
</p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getgrent</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;grp.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error or
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> end of file</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec4.html#inta30">167</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structgroup</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getgrgid</span>(gid_t <span class="docEmphItalicAlt">gid</span>);</pre><BR>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;grp.h&gt;</pre><BR>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec4.html#inta103">166</a></p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structgroup</pre><BR>
</p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getgrnam</span>(const char *<span class="docEmphItalicAlt">name</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;grp.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec4.html#inta103">166</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getgroups</span>(int <span class="docEmphItalicAlt">gidsetsize</span>, gid_t <span class="docEmphItalicAlt">grouplist</span>[]);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">Returns: number of supplementary group
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> IDs if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec5.html#inta105">168</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structhostent</pre><br>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">gethostent</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta31">553</a></p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">gethostname</span>(char *<span class="docEmphItalicAlt">name</span>, int <span class="docEmphItalicAlt">namelen</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec9.html#inta107">172</a></P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getlogin</span>(void);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: pointer to string giving login
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> name if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec15.html#inta108">256</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID224"></a><div class="v1"><a href="app01.html#PLID224">[View full width]</a></div><pre><span class="docEmphStrong">getmsg</span>(int <span class="docEmphItalicAlt">filedes</span>, struct strbuf *restrict <span class="docEmphItalicAlt">ctlptr</span>,
      struct strbuf *restrict <span class="docEmphItalicAlt">dataptr</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">flagptr</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stropts.h&gt;*
<span class="docEmphasis">flagptr</span>: 0, RS_HIPRI</pre><BR>
</P><p class="docText">Returns: non-negative value if
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> OK, 1 on error<br>Platforms: Linux 2.4.22, Solaris 9</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec4.html#inta109">469</a></P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID226"></a><div class="v1"><a href="app01.html#PLID226">[View full width]</a></div><pre><span class="docEmphStrong">getnameinfo</span>(const struct sockaddr *restrict <span class="docEmphItalicAlt">addr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> socklen_t <span class="docEmphItalicAlt">alen</span>,
            char *restrict <span class="docEmphItalicAlt">host</span>, socklen_t <span class="docEmphItalicAlt">hostlen</span>
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">, char *restrict <span class="docEmphItalicAlt">service</span>,
            socklen_t <span class="docEmphItalicAlt">servlen</span>, unsigned int <span class="docEmphItalicAlt">flags</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt; &lt;netdb.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, nonzero
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta110">556</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structnetent</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getnetbyaddr</span>(uint32_t <span class="docEmphItalicAlt">net</span>, int <span class="docEmphItalicAlt">type</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structnetent</pre><br>
</p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getnetbyname</span>(const char *<span class="docEmphItalicAlt">name</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structnetent</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getnetent</span>(void);</pre><BR>

</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID237"></a><div class="v1"><a href="app01.html#PLID237">[View full width]</a></div><pre><span class="docEmphStrong">getopt</span>(int <span class="docEmphItalicAlt">argc</span>, const * const <span class="docEmphItalicAlt">argv[]</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">options</span>);</pre><br>

</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;fcntl.h&gt;
extern int optind, opterr, optopt;
extern char *optarg;</pre><br>
</p><p class="docText">Returns: the next option
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> character, or 1 when all options have been
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> processed</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch21lev1sec5.html#inta114">774</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID239"></a><div class="v1"><a href="app01.html#PLID239">[View full width]</a></div><pre><span class="docEmphStrong">getpeername</span>(int <span class="docEmphItalicAlt">sockfd</span>, struct sockaddr *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">addr</span>,
            socklen_t *restrict <span class="docEmphItalicAlt">alenp</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta115">561</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getpgid</span>(pid_t <span class="docEmphItalicAlt">pid</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: process group ID if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec4.html#inta116">269</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getpgrp</span>(void);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: process group ID of calling process</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec4.html#inta117">269</a></P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getpid</span>(void);</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: process ID of calling process</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec2.html#inta98">210</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID247"></a><div class="v1"><a href="app01.html#PLID247">[View full width]</a></div><pre><span class="docEmphStrong">getpmsg</span>(int <span class="docEmphItalicAlt">filedes,</span> struct strbuf *restrict <span class="docEmphItalicAlt">ctlptr,</span>
        struct strbuf *restrict <span class="docEmphItalicAlt">dataptr,</span> int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">bandptr</span>,
        int *restrict <span class="docEmphItalicAlt">flagptr</span>);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID248"></a><div class="v1"><a href="app01.html#PLID248">[View full width]</a></div><pre>&lt;stropts.h&gt;
          *<span class="docEmphItalicAlt">flagptr</span>: 0, MSG_HIPRI, MSG_BAND,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> MSG_ANY</pre><BR>
</P><p class="docText">Returns: non-negative value if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error<br>Platforms: Linux 2.4.22, Solaris 9</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec4.html#inta119">469</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText"><span class="docEmphStrong"><tt>getppid</tt></span><tt>(void);</tt></p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: parent process ID of calling
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> process</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch08lev1sec2.html#inta98">210</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structprotoent</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">*getprotobyname</span>(const char *<span class="docEmphItalicAlt">name</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer if OK, NULL on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structprotoent</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getprotobynumber</span>(int <span class="docEmphItalicAlt">proto</span>);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structprotoent</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getprotoent</span>(void);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error.</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta32">554</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structpasswd</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getpwent</span>(void);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pwd.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error or
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> end of file</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec2.html#inta34">164</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structpasswd</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getpwnam</span>(const char *<span class="docEmphItalicAlt">name</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pwd.h&gt;</pre><BR>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec2.html#inta125">163</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structpasswd</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getpwuid</span>(uid_t<span class="docEmphItalicAlt">uid</span>);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pwd.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec2.html#inta125">163</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getrlimit</span>(int <span class="docEmphItalicAlt">resource</span>, struct rlimit *<span class="docEmphItalicAlt">rlptr</span>);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/resource.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, nonzero on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch07lev1sec11.html#inta127">202</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">gets</span>(char *<span class="docEmphItalicAlt">buf</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P><p class="docText">Returns: <tt>buf</tt> if OK, <tt>NULL</tt> on end of file
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> or error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p<a class="docLink" href="ch05lev1sec7.html#inta64">142</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structservent</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getservbyname</span>(const char *<span class="docEmphItalicAlt">name</span>, const char *<span class="docEmphItalicAlt">proto</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta35">555</a></p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structservent</pre><BR>
</p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getservbyport</span>(int <span class="docEmphItalicAlt">port</span>, const char *<span class="docEmphItalicAlt">proto</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta35">555</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structservent</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getservent</span>(void);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta35">555</a></p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getsid</span>(pid_t <span class="docEmphItalicAlt">pid</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: session leader's process
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> group ID if OK, 1 on error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch09lev1sec5.html#inta132">271</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID283"></a><div class="v1"><a href="app01.html#PLID283">[View full width]</a></div><pre><span class="docEmphStrong">getsockname</span>(int <span class="docEmphItalicAlt">sockfd</span>, struct sockaddr *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphasis">addr</span>,
            socklen_t *restrict <span class="docEmphItalicAlt">alenp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec4.html#inta133">561</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID285"></a><div class="v1"><a href="app01.html#PLID285">[View full width]</a></div><pre><span class="docEmphStrong">getsockopt</span>(int <span class="docEmphItalicAlt">sockfd</span>, int <span class="docEmphItalicAlt">level</span>, int <span class="docEmphItalicAlt">option</span>, void
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">val</span>,
           socklen_t *restrict <span class="docEmphItalicAlt">lenp</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec6.html#inta134">579</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structspwd</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getspent</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;shadow.h&gt;</pre><br>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</P><p class="docText">Platforms: Linux 2.4.22, Solaris 9</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec3.html#inta36">166</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structspwd</pre><BR>
</P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">getspnam</span>(const char *<span class="docEmphasis">name</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;shadow.h&gt;</pre><br>
</P><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p><p class="docText">Platforms: Linux 2.4.22, Solaris 9</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec3.html#inta36">166</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID293"></a><div class="v1"><a href="app01.html#PLID293">[View full width]</a></div><pre><span class="docEmphStrong">gettimeofday</span>(struct timeval *restrict <span class="docEmphItalicAlt">tp</span>, void
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">tzp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/time.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 always</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec10.html#inta137">173</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>uid_t</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">getuid</span>(void);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: real user ID of calling process</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch08lev1sec2.html#inta98">210</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structtm</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">gmtime</span>(const time_t *<span class="docEmphItalicAlt">calptr</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><br>
</P><p class="docText">Returns: pointer to broken-down time</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec10.html#inta139">175</a></P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">grantpt</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</P><p class="docText">Returns: 0 on success, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p><p class="docText">Platforms: FreeBSD 5.2.1, Linux 2.4.22, Solaris 9</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch19lev1sec3.html#inta140">682</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>uint32_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">htonl</span>(uint32_t <span class="docEmphItalicAlt">hostint32</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;arpa/inet.h&gt;</pre><BR>
</p><p class="docText">Returns: 32-bit integer in network
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> byte order</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta142">550</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>uint16_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">htons</span>(uint16_t <span class="docEmphItalicAlt">hostint16</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;arpa/inet.h&gt;</pre><br>
</p><p class="docText">Returns: 16-bit integer in network
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> byte order</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta142">550</a></p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>constchar</pre><br>
</p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID307"></a><div class="v1"><a href="app01.html#PLID307">[View full width]</a></div><pre>*<span class="docEmphStrong">inet_ntop</span>(int <span class="docEmphItalicAlt">domain</span>, const void *restrict <span class="docEmphItalicAlt">addr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> char *restrict <span class="docEmphItalicAlt">str</span>,
           socklen_t <span class="docEmphItalicAlt">size</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;arpa/inet.h&gt;</pre><BR>
Returns: pointer to address string on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> success, <tt>NULL</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta143">552</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID309"></a><div class="v1"><a href="app01.html#PLID309">[View full width]</a></div><pre><span class="docEmphStrong">inet_pton</span>(int <span class="docEmphItalicAlt">domain</span>, const char *restrict <span class="docEmphItalicAlt">str</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> void *restrict <span class="docEmphItalicAlt">addr</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;arpa/inet.h&gt;</pre><br>
</p><p class="docText">Returns: 1 on success, 0 if the
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> format is invalid, or 1 on error</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta143">552</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">initgroups</span>(const char *<span class="docEmphItalicAlt">username</span>, gid_t <span class="docEmphItalicAlt">basegid</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID312"></a><div class="v1"><a href="app01.html#PLID312">[View full width]</a></div><pre>         &lt;grp.h&gt;    /* Linux &amp; Solaris */
         &lt;unistd.h&gt; /* FreeBSD &amp; Mac OS X *
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">/</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta142">168</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ioctl</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">request</span>, ...);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID314"></a><div class="v1"><a href="app01.html#PLID314">[View full width]</a></div><pre>         &lt;unistd.h&gt;        /* System V */
         &lt;sys/ioctl.h&gt;     /* BSD and Linux */
         &lt;stropts.h&gt;       /* XSI STREAMS *
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">/</pre><BR>
</P><p class="docText">Returns: 1 on error, something else if OK</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch03lev1sec15.html#inta146">83</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">isastream</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stropts.h&gt;</pre><br>
</p><p class="docText">Returns: 1 (true) if STREAMS device, 0 
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(false) otherwise</p><p class="docText">Platforms: Linux 2.4.22, Solaris 9</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch14lev1sec4.html#inta147">465</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">isatty</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P><p class="docText">Returns: 1 (true) if terminal device, 0 
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(false) otherwise</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch18lev1sec9.html#inta148">655</a></p></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre> <span class="docEmphStrong">kill</span>(pid_t <span class="docEmphItalicAlt">pid</span>, int <span class="docEmphItalicAlt">signo</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch10lev1sec9.html#inta149">312</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID321"></a><div class="v1"><a href="app01.html#PLID321">[View full width]</a></div><pre><span class="docEmphStrong">lchown</span>(const char *<span class="docEmphItalicAlt">pathname</span>, uid_t <span class="docEmphItalicAlt">owner</span>, gid_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">group</span>);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch04lev1sec11.html#inta15">102</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">link</span>(const char *<span class="docEmphItalicAlt">existingpath</span>, const char *<span class="docEmphItalicAlt">newpath</span>);</pre><BR>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch04lev1sec15.html#inta151">109</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">listen</span>(int <span class="docEmphItalicAlt">sockfd</span>, int <span class="docEmphItalicAlt">backlog</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec4.html#inta152">563</a></p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>structtm</pre><br>
</p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">localtime</span>(const time_t *<span class="docEmphItalicAlt">calptr</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><br>
</p><p class="docText">Returns: pointer to broken-down time</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec10.html#inta139">175</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">longjmp</span>(jmp_buf <span class="docEmphItalicAlt">env</span>, int <span class="docEmphItalicAlt">val</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;setjmp.h&gt;</pre><BR>
</P><p class="docText">This function never returns</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec10.html#inta154">197</a></P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>off_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">lseek</span>(int <span class="docEmphasis">filedes</span>, off_t <span class="docEmphItalicAlt">offset</span>, int <span class="docEmphItalicAlt">whence</span>);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;
<span class="docEmphasis">whence</span>; SEEK_SET, SEEK_CUR, SEEK_END</pre><br>
</p><p class="docText">Returns: new
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> file offset if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch03lev1sec6.html#inta155">63</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID334"></a><div class="v1"><a href="app01.html#PLID334">[View full width]</a></div><pre><span class="docEmphStrong">lstat</span>(const char *restrict <span class="docEmphItalicAlt">pathname</span>, struct stat
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">buf</span>;</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/stat.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch04lev1sec2.html#inta81">87</a></p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">malloc</span>(size_t <span class="docEmphItalicAlt">size</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</p><p class="docText">Returns: non-null pointer if OK, <tt>NULL</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch07lev1sec8.html#inta08">189</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">mkdir</span>(const char *<span class="docEmphItalicAlt">pathname</span>, mode_t <span class="docEmphItalicAlt">mode</span>;</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID339"></a><div class="v1"><a href="app01.html#PLID339">[View full width]</a></div><pre>&lt;sys/stat.h&gt;
<span class="docEmphasis">mode</span>: S_IS[UG]ID, S_ISVTX, S_I[RWX]
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(USR|GRP|OTH)</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch04lev1sec20.html#inta158">119</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">mkfifo</span>(const char *<span class="docEmphItalicAlt">pathname</span>, mode_t <span class="docEmphItalicAlt">mode</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID341"></a><div class="v1"><a href="app01.html#PLID341">[View full width]</a></div><pre>&lt;sys/stat.h&gt;
<span class="docEmphasis">mode</span>: S_IS[UG]ID, S_ISVTX, S_I[RWX]
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(USR|GRP|OTH)</pre><br>
</p><p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec5.html#inta159">514</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">mkstemp</span>(char *<span class="docEmphItalicAlt">template</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><BR>
</P><p class="docText">Returns: file descriptor if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch05lev1sec13.html#inta160">158</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>time_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">mktime</span>(struct tm *<span class="docEmphItalicAlt">tmptr</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><BR>
</p><p class="docText">Returns: calendar time if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch06lev1sec10.html#inta161">175</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>caddr_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID346"></a><div class="v1"><a href="app01.html#PLID346">[View full width]</a></div><pre><span class="docEmphStrong">mmap</span>(void *<span class="docEmphItalicAlt">addr</span>, size_t <span class="docEmphItalicAlt">len</span>, int <span class="docEmphItalicAlt">prot</span>, int <span class="docEmphItalicAlt">flag</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">filedes</span>, off_t <span class="docEmphItalicAlt">off</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/mman.h&gt;
<span class="docEmphasis">prot</span>: PROT_READ, PROT_WRITE, PROT_EXEC, PROT_NONE
<span class="docEmphasis">flag</span>: MAP_FIXED, MAP_SHARED, MAP_PRIVATE</pre><BR>
</p><p class="docText">Returns:
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> starting address of mapped region if OK,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> MAP_FAILED on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch14lev1sec9.html#inta162">487</a></p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">mprotect</span>(void *<span class="docEmphItalicAlt">addr</span>, size_t <span class="docEmphItalicAlt">len</span>, int <span class="docEmphItalicAlt">prot</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/mman.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch14lev1sec9.html#inta163">489</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">msgctl</span>(int <span class="docEmphItalicAlt">msqid</span>, int <span class="docEmphItalicAlt">cmd</span>, struct msqid_ds *<span class="docEmphItalicAlt">buf</span> );</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/msg.h&gt;
<span class="docEmphasis">cmd</span>: IPC_STAT, IPC_SET, IPC_RMID</pre><BR>
</P><p class="docText">Returns: 0 if OK,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> 1 on error<BR>Platforms: FreeBSD 5.2.1, Linux 2.4
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">.22, Solaris 9</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec7.html#inta164">524</a></P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">msgget</span>(key_t <span class="docEmphItalicAlt">key</span>, int <span class="docEmphItalicAlt">flag</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/msg.h&gt;
<span class="docEmphasis">flag</span>: 0, IPC_CREAT, IPC_EXCL</pre><br>
</P><p class="docText">Returns: message queue
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> ID if OK, 1 on error<br>Platforms: FreeBSD 5.2.1,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> Linux 2.4.22, Solaris 9</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec7.html#inta165">524</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID354"></a><div class="v1"><a href="app01.html#PLID354">[View full width]</a></div><pre><span class="docEmphStrong">msgrcv</span>(int <span class="docEmphItalicAlt">msqid</span>, void *<span class="docEmphItalicAlt">ptr</span>, size_t <span class="docEmphItalicAlt">nbytes</span>, long
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">type</span>, int <span class="docEmphItalicAlt">flag</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/msg.h&gt;
<span class="docEmphasis">flag</span>: 0, IPC_NOWAIT, MSG_NOERROR</pre><BR>
</P><p class="docText">Returns: size of
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> data portion of message if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error<BR>Platforms: FreeBSD 5.2.1, Linux 2.4.22, Solaris 9</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec7.html#inta166">526</a></P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID356"></a><div class="v1"><a href="app01.html#PLID356">[View full width]</a></div><pre><span class="docEmphStrong">msgsnd</span>(int <span class="docEmphItalicAlt">msqid</span>, const void *<span class="docEmphItalicAlt">ptr</span>, size_t <span class="docEmphItalicAlt">nbytes</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">flag</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/msg.h&gt;
<span class="docEmphasis">flag</span>: 0, IPC_NOWAIT</pre><br>
</P><p class="docText">Returns: 0 if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error<br>Platforms: FreeBSD 5.2.1, Linux 2.4.22, Solaris 9</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec7.html#inta167">525</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">msync</span>(void *<span class="docEmphItalicAlt">addr</span>, size_t <span class="docEmphItalicAlt">len</span>, int <span class="docEmphItalicAlt">flags</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/mman.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch14lev1sec9.html#inta168">490</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">munmap</span>(caddr_t <span class="docEmphItalicAlt">addr</span>, size_t <span class="docEmphItalicAlt">len</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/mman.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="app03lev1sec14.html#inta169">490</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>uint32_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ntohl</span>(uint32_t<span class="docEmphItalicAlt">netint32</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;arpa/inet.h&gt;</pre><BR>
</p><p class="docText">Returns: 32-bit integer in host byte
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> order</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta142">550</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>uint16_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ntohs</span>(uint16_t <span class="docEmphItalicAlt">netint16</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;arpa/inet.h&gt;</pre><br>
</p><p class="docText">Returns: 16-bit integer in host byte
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> order</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch16lev1sec3.html#inta142">550</a></p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID366"></a><div class="v1"><a href="app01.html#PLID366">[View full width]</a></div><pre><span class="docEmphStrong">open</span>(const char *<span class="docEmphItalicAlt">pathname</span>, int <span class="docEmphItalicAlt">oflag</span>, ... /*
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> mode_t <span class="docEmphItalicAlt">mode</span> */ );</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID367"></a><div class="v1"><a href="app01.html#PLID367">[View full width]</a></div><pre>&lt;fcntl.h&gt;
<span class="docEmphasis">oflag</span>: O_RDONLY, O_WRONLY, O_RDWR;
       O_APPEND, O_CREAT, O_DSYNC, O_EXCL, O_NOCTTY,
       O_NONBLOCK, O_RSYNC, O_SYNC, O_TRUNC
<span class="docEmphItalicAlt">mode</span>: S_IS[UG]ID, S_ISVTX, S_I[RWX]
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(USR|GRP|OTH)</pre><br>
</P><p class="docText">Returns: file descriptor if OK, 1
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> on error<BR>Platforms: O_FSYNC flag on FreeBSD 5.2.1
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> and Mac OS X 10.3</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch03lev1sec3.html#inta172">60</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>DIR</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">opendir</span>(const char *<span class="docEmphItalicAlt">pathname</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;direct.h&gt;</pre><br>
</p><p class="docText">Returns: pointer if OK, <tt>NULL</tt> on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch04lev1sec21.html#inta173">120</a></P></td></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">openlog</span>(char *<span class="docEmphItalicAlt">ident</span>, int <span class="docEmphItalicAlt">option</span>, int <span class="docEmphItalicAlt">facility</span>;</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID371"></a><div class="v1"><a href="app01.html#PLID371">[View full width]</a></div><pre>&lt;syslog.h&gt;
  <span class="docEmphItalicAlt">option</span>: LOG_CONS, LOG_NDELAY, LOG_NOWAIT,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> LOG_ODELAY,
          LOG_PERROR, LOG_PID
<span class="docEmphItalicAlt">facility</span>: LOG_AUTH, LOG_AUTHPRIV, LOG_CRON,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> LOG_DAEMON,
          LOG_FTP, LOG_KERN, LOG_LOCAL[0-7], LOG_LPR,
          LOG_MAIL, LOG_NEWS, LOG_SYSLOG, LOG_USER
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">, LOG_UUCP</pre><br>
</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch13lev1sec4.html#inta293">430</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>long</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pathconf</span>(const char *<span class="docEmphItalicAlt">pathname</span>, int <span class="docEmphItalicAlt">name</span>);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID373"></a><div class="v1"><a href="app01.html#PLID373">[View full width]</a></div><pre>&lt;unistd.h&gt;
<span class="docEmphItalicAlt">name</span>: _PC_ASYNC_IO, _PC_CHOWN_RESTRICTED,
      _PC_FILESIZEBITS, _PC_LINK_MAX, _PC_MAX_CANON,
      _PC_MAX_INPUT, _PC_NAME_MAX, _PC_NO_TRUNC,
      _PC_PATH_MAX, _PC_PIPE_BUF, _PC_PRIO_IO,
      _PC_SYMLINK_MAX, _PC_SYNC_IO,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> _PC_VDISABLE</pre><BR>
</P><p class="docText">Returns: corresponding value if OK,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> 1 on</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch02lev1sec5.html#inta175">41</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pause</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p><p class="docText">Returns: 1 with <tt>errno</tt> set to <tt>EINTR</tt></p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch10lev1sec10.html#inta176">313</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pclose</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p><p class="docText">Returns: termination status of <tt>popen</tt>
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphasis">cmdstring</span>, or 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec3.html#inta177">503</a></p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">perror</span>(const char *<span class="docEmphItalicAlt">msg</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch01lev1sec7.html#inta178">15</a></p></td></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pipe</span>(int <span class="docEmphItalicAlt">filedes[2]</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec2.html#inta179">497</a></P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID382"></a><div class="v1"><a href="app01.html#PLID382">[View full width]</a></div><pre><span class="docEmphStrong">poll</span>(struct pollfd <span class="docEmphItalicAlt">fdarray</span>[], nfds_t <span class="docEmphItalicAlt">nfds</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">timeout</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;poll.h&gt;</pre><br>
</p><p class="docText">Returns: count of ready descriptors, 0 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> timeout, 1 on error<br>Platforms: FreeBSD 5.2.1,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> Linux 2.4.22, Solaris 9</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch14lev1sec5.html#inta180">479</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>FILE</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">*popen</span>(const char *<span class="docEmphItalicAlt">cmdstring</span>, const char *<span class="docEmphItalicAlt">type</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
<span class="docEmphasis">type</span>: "r", "w"</pre><BR>
</P><p class="docText">Returns: file pointer if OK, <tt>NULL</tt> on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch15lev1sec3.html#inta177">503</a></p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">posix_openpt</span>(int <span class="docEmphItalicAlt">oflag</span>);</pre><br>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;
&lt;fcntl.h&gt;
<span class="docEmphItalicAlt">oflag</span>: O_RWDR, O_NOCTTY</pre><br>
</p><p class="docText">Returns: file descriptor of
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> next available PTY master if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error<br>Platforms: FreeBSD 5.2.1</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch19lev1sec3.html#inta182">681</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID388"></a><div class="v1"><a href="app01.html#PLID388">[View full width]</a></div><pre><span class="docEmphStrong">pread</span>(int <span class="docEmphItalicAlt">filedes</span>, void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>, off_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">offset</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P><p class="docText">Returns: number of bytes read, 0 if end
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> of file, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch03lev1sec11.html#inta183">75</a></P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">printf</span>(const char *restrict <span class="docEmphItalicAlt">format</span>, ...);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p><p class="docText">Returns: number of characters output if
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> OK, negative value if output error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch05lev1sec11.html#inta70">149</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID392"></a><div class="v1"><a href="app01.html#PLID392">[View full width]</a></div><pre><span class="docEmphStrong">pselect</span>(int <span class="docEmphItalicAlt">maxfdp1</span>, fd_set *restrict <span class="docEmphItalicAlt">readfds</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> fd_set *restrict <span class="docEmphItalicAlt">writefds</span>,
        fd_set *restrict <span class="docEmphItalicAlt">exceptfds</span>, const struct
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> timespec *restrict <span class="docEmphItalicAlt">tsptr</span>,
        const sigset_t *restrict <span class="docEmphItalicAlt">sigmask</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/select.h&gt;</pre><BR>
</p><p class="docText">Returns: count of ready descriptors,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> 0 on timeout, 1 on error<BR>Platforms: FreeBSD 5.2
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">.1, Linux 2.4.22, Mac OS X 10.3</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch14lev1sec5.html#inta185">478</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">psignal</span>(int <span class="docEmphItalicAlt">signo</span>, const char *<span class="docEmphItalicAlt">msg</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;
&lt;siginfo.h&gt; /* on Solaris */</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch10lev1sec21.html#inta186">352</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID396"></a><div class="v1"><a href="app01.html#PLID396">[View full width]</a></div><pre><span class="docEmphStrong">pthread_atfork</span>(void (*<span class="docEmphItalicAlt">prepare</span>)(void), void 
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(*<span class="docEmphItalicAlt">parent</span>)(void),
               void (*<span class="docEmphItalicAlt">child</span>)(void);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec9.html#inta187">417</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_attr_destroy</span>(pthread_attr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta188">389</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID400"></a><div class="v1"><a href="app01.html#PLID400">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_getdetachstate</span>(const pthread_attr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">attr</span>,
                            int *<span class="docEmphItalicAlt">detachstate</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta189">390</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID402"></a><div class="v1"><a href="app01.html#PLID402">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_getguardsize</span>(const pthread_attr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">attr</span>,
                          size_t *restricts
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">guardsize</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta190">392</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID404"></a><div class="v1"><a href="app01.html#PLID404">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_getstack</span>(const pthread_attr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">attr</span>, void
                      **restrict <span class="docEmphItalicAlt">stackaddr</span>, size_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict<span class="docEmphItalicAlt">stacksize</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, error number on failure</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta191">391</a></p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID406"></a><div class="v1"><a href="app01.html#PLID406">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_getstacksize</span>(const pthread_attr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">attr</span>,
                          size_t *restrict <span class="docEmphItalicAlt">stacksize</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, error number on failure</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta190">392</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_attr_init</span>(pthread_attr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta188">389</a></P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID410"></a><div class="v1"><a href="app01.html#PLID410">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_setdetachstate</span>(pthread_attr_t *<span class="docEmphItalicAlt">attr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">detachstate</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta189">390</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID412"></a><div class="v1"><a href="app01.html#PLID412">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_setguardsize</span>(pthread_attr_t *<span class="docEmphItalicAlt">attr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> size_t <span class="docEmphItalicAlt">guardsize</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p><p class="docText">Returns: 0 if OK, error number on failure</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta195">392</a></p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID414"></a><div class="v1"><a href="app01.html#PLID414">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_setstack</span>(const pthread_attr_t *<span class="docEmphItalicAlt">attr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> void *<span class="docEmphItalicAlt">stackaddr</span>,
                      size_t *<span class="docEmphItalicAlt">stacksize</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta191">391</a></p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID416"></a><div class="v1"><a href="app01.html#PLID416">[View full width]</a></div><pre><span class="docEmphStrong">pthread_attr_setstacksize</span>(pthread_attr_t *<span class="docEmphItalicAlt">attr</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> size_t <span class="docEmphItalicAlt">stacksize</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec3.html#inta195">392</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cancel</span>(pthread_t <span class="docEmphItalicAlt">tid</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, error number on failure</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch11lev1sec5.html#inta198">365</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cleanup_pop</span>(int <span class="docEmphItalicAlt">execute</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch11lev1sec5.html#inta199">365</a></P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cleanup_push</span>(void (*<span class="docEmphItalicAlt">rtn</span>)(void *), void *<span class="docEmphItalicAlt">arg</span>);</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch11lev1sec5.html#inta198">365</a></p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_condattr_destroy</span>(pthread_condattr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec4.html#inta201">401</a></p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID426"></a><div class="v1"><a href="app01.html#PLID426">[View full width]</a></div><pre><span class="docEmphStrong">pthread_condattr_getpshared</span>(const
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> pthread_condattr_t *restrict <span class="docEmphItalicAlt">attr</span>,
                            int *restrict <span class="docEmphItalicAlt">pshared</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec4.html#inta235">401</a></P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_condattr_init</span>(pthread_condattr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec4.html#inta235">401</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID430"></a><div class="v1"><a href="app01.html#PLID430">[View full width]</a></div><pre><span class="docEmphStrong">pthread_condattr_setpshared</span>(pthread_condattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">attr</span>, int <span class="docEmphItalicAlt">pshared</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P><p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch12lev1sec4.html#inta235">401</a></p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cond_broadcast</span>(pthread_cond_t *<span class="docEmphItalicAlt">cond</span>);</pre><br>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p><p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch11lev1sec6.html#inta205">384</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cond_destroy</span>(pthread_cond_t *<span class="docEmphItalicAlt">cond</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P><p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p.<a class="docLink" href="ch11lev1sec6.html#inta206">383</a></P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cond_init</span>(pthread_cond_t *restrict <span class="docEmphItalicAlt">cond</span>,
                  pthread_condattr_t *restrict <span class="docEmphasis">attr</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta206">383</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cond_signal</span>(pthread_cond_t *<span class="docEmphItalicAlt">cond</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta205">384</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID440"></a><div class="v1"><a href="app01.html#PLID440">[View full width]</a></div><pre><span class="docEmphStrong">pthread_cond_timedwait</span>(pthread_cond_t *restrict <span class="docEmphItalicAlt">cond</span>,
                       pthread_mutex_t *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">mutex</span>,
                       const struct timespec
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">timeout</span>);</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta207">383</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_cond_wait</span>(pthread_cond_t *restrict <span class="docEmphItalicAlt">cond</span>,
                  pthread_mutex_t *restrict <span class="docEmphItalicAlt">mutex</span>);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta207">383</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID444"></a><div class="v1"><a href="app01.html#PLID444">[View full width]</a></div><pre><span class="docEmphStrong">pthread_create</span>(pthread_t *restrict <span class="docEmphItalicAlt">tidp</span>,
               const pthread_attr_t *restrict <span class="docEmphItalicAlt">attr</span>,
               void *(*<span class="docEmphasis">start_rtn</span>)(void), void
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphasis">arg</span>);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec3.html#inta211">357</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_detach</span>(pthread_t <span class="docEmphItalicAlt">tid</span>);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec5.html#inta212">368</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_equal</span>(pthread_t <span class="docEmphItalicAlt">tid1</span>, pthread_t <span class="docEmphItalicAlt">tid2</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: nonzero if equal, 0 otherwise</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec3.html#inta213">357</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_exit</span>(void *<span class="docEmphItalicAlt">rval_ptr</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec5.html#inta214">361</a>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_getconcurrency</span>(void);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p>
<p class="docText">Returns: current concurrency level</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec3.html#inta215">393</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">pthread_getspecific</span>(pthread_key_t <span class="docEmphItalicAlt">key</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p>
<p class="docText">Returns: thread-specific data value or <tt>NULL</tt> if no value has been associated with the key</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec6.html#inta216">408</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_join</span>(pthread_t <span class="docEmphItalicAlt">thread</span>, void **<span class="docEmphItalicAlt">rval_ptr</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec5.html#inta217">361</a>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID458"></a><div class="v1"><a href="app01.html#PLID458">[View full width]</a></div><pre><span class="docEmphStrong">pthread_key_create</span>(pthread_key_t *<span class="docEmphItalicAlt">keyp</span>, void 
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(*<span class="docEmphItalicAlt">destructor</span>)(void *);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec6.html#inta218">406</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_key_delete</span>(pthread_key_t *<span class="docEmphItalicAlt">key</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec6.html#inta219">407</a>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_kill</span>(pthread_t <span class="docEmphItalicAlt">thread</span>, int <span class="docEmphItalicAlt">signo</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec8.html#inta220">414</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_mutexattr_destroy</span>(pthread_mutexattr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta221">393</a>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID466"></a><div class="v1"><a href="app01.html#PLID466">[View full width]</a></div><pre><span class="docEmphStrong">pthread_mutexattr_getpshared</span>(const
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> pthread_mutexattr_t *restrict <span class="docEmphItalicAlt">attr</span>, int *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">pshared</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta222">394</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID468"></a><div class="v1"><a href="app01.html#PLID468">[View full width]</a></div><pre><span class="docEmphStrong">pthread_mutexattr_gettype</span>(const
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> pthread_mutexattr_t *restrict <span class="docEmphItalicAlt">attr</span>,
                          int *restrict <span class="docEmphItalicAlt">type</span>);</pre><BR>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta223">395</a>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_mutexattr_init</span>(pthread_mutexattr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta221">393</a>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID472"></a><div class="v1"><a href="app01.html#PLID472">[View full width]</a></div><pre><span class="docEmphStrong">pthread_mutexattr_setpshared</span>(pthread_mutexattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">attr</span>, int <span class="docEmphItalicAlt">pshared</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta222">394</a>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID474"></a><div class="v1"><a href="app01.html#PLID474">[View full width]</a></div><pre><span class="docEmphStrong">pthread_mutexattr_settype</span>(pthread_mutexattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">attr</span>, int <span class="docEmphItalicAlt">type</span>);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta223">395</a>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_mutex_destroy</span>(pthread_mutex_t *<span class="docEmphItalicAlt">mutex</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta227">371</a>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID478"></a><div class="v1"><a href="app01.html#PLID478">[View full width]</a></div><pre><span class="docEmphStrong">pthread_mutex_init</span>(pthread_mutex_t *restrict <span class="docEmphItalicAlt">mutex</span>,
                   const pthread_mutexattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">attr</span>);</pre><br>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta227">371</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_mutex_lock</span>(pthread_mutex_t *<span class="docEmphItalicAlt">mutex</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta229">371</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_mutex_trylock</span>(pthread_mutex_t *<span class="docEmphItalicAlt">mutex</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta229">371</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_mutex_unlock</span>(pthread_mutex_t *<span class="docEmphItalicAlt">mutex</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta229">371</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID486"></a><div class="v1"><a href="app01.html#PLID486">[View full width]</a></div><pre><span class="docEmphStrong">pthread_once</span>(pthread_once_t *<span class="docEmphItalicAlt">initflag</span>, void 
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">(*<span class="docEmphItalicAlt">initfn</span>)(void);</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;
pthread_once_t <span class="docEmphasis">initflag</span> = PTHREAD_ONCE_INIT;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec6.html#inta232">408</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID488"></a><div class="v1"><a href="app01.html#PLID488">[View full width]</a></div><pre><span class="docEmphStrong">pthread_rwlockattr_destroy</span>(pthread_rwlockattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta233">400</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID490"></a><div class="v1"><a href="app01.html#PLID490">[View full width]</a></div><pre><span class="docEmphStrong">pthread_rwlockattr_getpshared</span>(const
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> pthread_rwlockattr_t *restrict <span class="docEmphItalicAlt">attr</span>,
                              int *restrict <span class="docEmphItalicAlt">pshared</span>);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta233">400</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlockattr_init</span>(pthread_rwlockattr_t *<span class="docEmphItalicAlt">attr</span>);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta235">400</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID494"></a><div class="v1"><a href="app01.html#PLID494">[View full width]</a></div><pre><span class="docEmphStrong">pthread_rwlockattr_setpshared</span>(pthread_rwlockattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">attr</span>, int <span class="docEmphItalicAlt">pshared</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec4.html#inta233">400</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlock_destroy</span>(pthread_rwlock_t *<span class="docEmphItalicAlt">rwlock</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta237">379</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID498"></a><div class="v1"><a href="app01.html#PLID498">[View full width]</a></div><pre><span class="docEmphStrong">pthread_rwlock_init</span>(pthread_rwlock_t *restrict <span class="docEmphItalicAlt">rwlock</span>,
                    const pthread_rwlockattr_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">attr</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta238">379</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlock_rdlock</span>(pthread_rwlock_t *<span class="docEmphItalicAlt">rwlock</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta239">379</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlock_tryrdlock</span>(pthread_rwlock_t *<span class="docEmphItalicAlt">rwlock</span>);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta237">379</a>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlock_trywrlock</span>(pthread_rwlock_t *<span class="docEmphItalicAlt">rwlock</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta237">379</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlock_unlock</span>(pthread_rwlock_t *<span class="docEmphItalicAlt">rwlock</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta237">379</a>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_rwlock_wrlock</span>(pthread_rwlock_t *<span class="docEmphItalicAlt">rwlock</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec6.html#inta237">379</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>pthread_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_self</span>(void);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p>
<p class="docText">Returns: thread ID of the calling thread</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch11lev1sec4.html#inta244">357</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_setcancelstate</span>(int <span class="docEmphItalicAlt">state</span>, int *<span class="docEmphItalicAlt">oldstate</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec7.html#inta245">410</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_setcanceltype</span>(int <span class="docEmphItalicAlt">type</span>, int *<span class="docEmphItalicAlt">oldtype</span>);</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec7.html#inta246">411</a>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_setconcurrency</span>(int <span class="docEmphItalicAlt">level</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec3.html#inta215">393</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID518"></a><div class="v1"><a href="app01.html#PLID518">[View full width]</a></div><pre><span class="docEmphStrong">pthread_setspecific</span>(pthread_key_t <span class="docEmphItalicAlt">key</span>, const void
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">value</span>);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, error number on failure</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec6.html#inta216">408</a>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_sigmask</span>(int <span class="docEmphItalicAlt">how</span>, const sigset_t *restrict <span class="docEmphItalicAlt">set</span>,
                sigset_t *restrict&gt; <span class="docEmphItalicAlt">oset</span>);</pre><BR>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec8.html#inta249">413</a>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">pthread_testcancel</span>(void);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pthread.h&gt;</pre><BR>
</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec7.html#inta250">411</a>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">*ptsname</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</p>
<p class="docText">Returns: pointer to name of PTY slave if OK, <tt>NULL</tt> on error</p>
<p class="docText">Platforms: FreeBSD 5.2.1, Linux 2.4.22, Solaris 9</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch19lev1sec3.html#inta251">682</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">putc</span>(int <span class="docEmphItalicAlt">c</span>, FILE *<span class="docEmphItalicAlt">fp</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P>
<p class="docText">Returns: <span class="docEmphasis">c</span> if OK, <tt>EOF</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta253">142</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">putchar</span>(int <span class="docEmphItalicAlt">c</span>);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: <span class="docEmphasis">c</span> if OK, <tt>EOF</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta253">142</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">putchar_unlocked</span>(int <span class="docEmphItalicAlt">c</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p>
<p class="docText">Returns: <span class="docEmphasis">c</span> if OK, <tt>EOF</tt> on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta254">403</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">putc_unlocked</span>(int <span class="docEmphItalicAlt">c</span>, FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: <span class="docEmphasis">c</span> if OK, <tt>EOF</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec5.html#inta66">403</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">putenv</span>(char *<span class="docEmphItalicAlt">str</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, nonzero on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec9.html#inta256">194</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">putmsg</span>(int <span class="docEmphItalicAlt">filedes</span>, const struct strbuf *<span class="docEmphItalicAlt">ctlptr</span>,
       const struct strbuf *<span class="docEmphItalicAlt">dataptr</span>, int <span class="docEmphItalicAlt">flag</span>)</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stropts.h&gt;
<span class="docEmphItalicAlt">flag</span>: 0, RS_HIPRI</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p>
<p class="docText">Platforms: Linux 2.4.22, Solaris 9</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec4.html#inta257">463</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID538"></a><div class="v1"><a href="app01.html#PLID538">[View full width]</a></div><pre><span class="docEmphStrong">putpmsg</span>(int <span class="docEmphasis">filedes</span>, const struct strbuf *<span class="docEmphItalicAlt">ctlptr</span>,
        const struct strbuf *<span class="docEmphItalicAlt">dataptr</span>, int <span class="docEmphItalicAlt">band</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">flag</span>);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stropts.h&gt;
<span class="docEmphItalicAlt">flag</span>: 0, MSG_HIPRI, MSG_BAND</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</p>
<p class="docText">Platforms: Linux 2.4.22, Solaris 9</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec4.html#inta257">463</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">puts</span>(const char *<span class="docEmphItalicAlt">str</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: non-negative value if OK, <tt>EOF</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec7.html#inta259">143</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID542"></a><div class="v1"><a href="app01.html#PLID542">[View full width]</a></div><pre><span class="docEmphStrong">pwrite</span>(int <span class="docEmphItalicAlt">filedes</span>, const void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">, off_t <span class="docEmphItalicAlt">offset</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P>
<p class="docText">Returns: number of bytes written if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec11.html#inta183">75</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">raise</span>(int <span class="docEmphItalicAlt">signo</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec9.html#inta149">312</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">read</span>(int <span class="docEmphItalicAlt">filedes</span>, void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p>
<p class="docText">Returns: number of bytes read if OK, 0 if end of file, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec7.html#inta262">67</a></p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>struct<BR>dirent</pre><br>
</P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">readdir</span>(DIR *<span class="docEmphItalicAlt">dp</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;dirent.h&gt;</pre><BR>
</p>
<p class="docText">Returns: pointer if OK, <tt>NULL</tt> at end of directory or error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec21.html#inta173">120</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID551"></a><div class="v1"><a href="app01.html#PLID551">[View full width]</a></div><pre><span class="docEmphStrong">readlink</span>(const char *restrict <span class="docEmphItalicAlt">pathname</span>, char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">buf</span>,
         size_t <span class="docEmphItalicAlt">bufsize</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p>
<p class="docText">Returns: number of bytes read if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec17.html#inta264">115</a>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID553"></a><div class="v1"><a href="app01.html#PLID553">[View full width]</a></div><pre><span class="docEmphStrong">readv</span>(int <span class="docEmphItalicAlt">filedes</span>, const struct iovec *<span class="docEmphItalicAlt">iov</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">iovcnt</span>;</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/uio.h&gt;</pre><BR>
</p>
<p class="docText">Returns: number of bytes read if OK, 1 on error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec7.html#inta265">483</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">realloc</span>(void *<span class="docEmphItalicAlt">ptr</span>, size_t <span class="docEmphItalicAlt">newsize</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><BR>
</P>
<p class="docText">Returns: non-null pointer if OK, <tt>NULL</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec8.html#inta08">189</a>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">recv</span>(int <span class="docEmphItalicAlt">sockfd</span>, void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>, int <span class="docEmphItalicAlt">flags</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;sys/socket.h&gt;
<span class="docEmphasis">flags</span>: 0, MSG_PEEK, MSG_OOB, MSG_WAITALL</pre><BR>
</p>
<p class="docText">Returns: length of message in bytes, 0 if no messages are available and peer has done an orderly shutdown, or 1 on error</P>
<p class="docText">Platforms: <tt>MSG_TRUNC</tt> flag on Linux 2.4.22</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec5.html#inta267">567</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID559"></a><div class="v1"><a href="app01.html#PLID559">[View full width]</a></div><pre><span class="docEmphStrong">recvfrom</span>(int <span class="docEmphItalicAlt">sockfd</span>, void *restrict <span class="docEmphItalicAlt">buf</span>, size_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">len</span>, int <span class="docEmphItalicAlt">flags</span>,
         struct sockaddr *restrict <span class="docEmphItalicAlt">addr</span>, socklen_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">addrlen</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphasis">flags</span>: 0, MSG_PEEK, MSG_OOB, MSG_WAITALL</pre><br>
</P>
<p class="docText">Returns: length of message in bytes, 0 if no messages are available and peer has done an orderly shutdown, or 1 on error</P>
<p class="docText">Platforms: <tt>MSG_TRUNC</tt> flag on Linux 2.4.22</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec5.html#inta268">567</a>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">recvmsg</span>(int <span class="docEmphItalicAlt">sockfd</span>, struct msghdr *<span class="docEmphItalicAlt">msg</span>, int <span class="docEmphItalicAlt">flags</span>;</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphasis">flags</span>: 0, MSG_PEEK, MSG_OOB, MSG_WAITALL</pre><BR>
</p>
<p class="docText">Returns: length of message in bytes, 0 if no messages are available</P>
<p class="docText">and peer has done an orderly shutdown, or 1 on error</p>
<p class="docText">Platforms: <tt>MSG_TRUNC</tt> flag on Linux 2.4.22</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec5.html#inta269">568</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">remove</span>(const char *<span class="docEmphItalicAlt">pathname</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec15.html#inta270">111</a>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">rename</span>(const char *<span class="docEmphItalicAlt">oldname</span>, const char *<span class="docEmphItalicAlt">newname</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec15.html#inta271">111</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">rewind</span>(FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec10.html#inta272">147</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">rewinddir</span>(DIR *<span class="docEmphItalicAlt">dp</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;dirent.h&gt;</pre><br>
</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec20.html#inta18">120</a></p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">rmdir</span>(const char *<span class="docEmphItalicAlt">pathname</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec20.html#inta18">120</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">scanf</span>(const char *restrict <span class="docEmphItalicAlt">format</span>, ...);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P>
<p class="docText">Returns: number of input items assigned, <tt>EOF</tt> if input error or</p>
<p class="docText">end of file before any conversion</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">seekdir</span>(DIR *<span class="docEmphItalicAlt">dp</span>, long <span class="docEmphItalicAlt">loc</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;dirent.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec20.html#inta18">120</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID577"></a><div class="v1"><a href="app01.html#PLID577">[View full width]</a></div><pre><span class="docEmphStrong">select</span>(int <span class="docEmphItalicAlt">maxfdp1</span>, fd_set *restrict <span class="docEmphItalicAlt">readfds</span>,
       fd_set *restrict <span class="docEmphItalicAlt">writefds</span>, fd_set *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">exceptfds</span>, struct timeval *restrict <span class="docEmphItalicAlt">tvptr</span>);</pre><BR>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/select.h&gt;</pre><BR>
</p>
<p class="docText">Returns: count of ready descriptors, 0 on timeout, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec5.html#inta277">475</a></p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID579"></a><div class="v1"><a href="app01.html#PLID579">[View full width]</a></div><pre><span class="docEmphStrong">semctl</span>(int <span class="docEmphasis">semid</span>, int <span class="docEmphItalicAlt">semnum</span>, int <span class="docEmphItalicAlt">cmd</span>, ... /*
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> union semun <span class="docEmphItalicAlt">arg</span> */ );</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/sem.h&gt;
<span class="docEmphasis">cmd</span>: IPC_STAT, IPC_SET, IPC_RMID, GETPID, GETNCNT,
     GETZCNT, GETVAL, SETVAL, GETALL, SETALL</pre><br>
</p>
<p class="docText">Returns: (depends on command)</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec8.html#inta278">529</a>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">semget</span>(key_t <span class="docEmphItalicAlt">key</span>, int <span class="docEmphItalicAlt">nsems</span>, int <span class="docEmphItalicAlt">flag</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/sem.h&gt;
<span class="docEmphasis">flag</span>: 0, IPC_CREAT, IPC_EXCL</pre><br>
</P>
<p class="docText">Returns: semaphore ID if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec8.html#inta279">529</a>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID583"></a><div class="v1"><a href="app01.html#PLID583">[View full width]</a></div><pre><span class="docEmphStrong">semop</span>(int <span class="docEmphItalicAlt">semid</span>, struct sembuf <span class="docEmphItalicAlt">semoparray</span>[],
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> size_t <span class="docEmphItalicAlt">nops</span>);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/sem.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec8.html#inta280">530</a></p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID585"></a><div class="v1"><a href="app01.html#PLID585">[View full width]</a></div><pre><span class="docEmphStrong">send</span>(int <span class="docEmphItalicAlt">sockfd</span>, const void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">flags</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphItalicAlt">flags</span>: 0, MSG_DONTROUTE, MSG_EOR, MSG_OOB</pre><BR>
</P>
<p class="docText">Returns: number of bytes sent if OK, 1 on error</p>
<p class="docText">Platforms: <tt>MSG_DONTWAIT</tt> flag on FreeBSD 5.2.1, Linux 2.4.22, Mac OS X 10.3 <tt>MSG_EOR</tt> flag not on Solaris 9</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec5.html#inta281">565</a>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID587"></a><div class="v1"><a href="app01.html#PLID587">[View full width]</a></div><pre><span class="docEmphStrong">sendmsg</span>(int <span class="docEmphItalicAlt">sockfd</span>, const struct msghdr *<span class="docEmphItalicAlt">msg</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">flags</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphasis">flags</span>: 0, MSG_DONTROUTE, MSG_EOR, MSG_OOB</pre><br>
</p>
<p class="docText">Returns: number of bytes sent if OK, 1 on error</p>
<p class="docText">Platforms: <tt>MSG_DONTWAIT</tt> flag on FreeBSD 5.2.1, Linux 2.4.22, Mac OS X 10.3 <tt>MSG_EOR</tt> flag not on Solaris 9</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec5.html#inta282">566</a>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID589"></a><div class="v1"><a href="app01.html#PLID589">[View full width]</a></div><pre><span class="docEmphStrong">sendto</span>(int <span class="docEmphItalicAlt">sockfd</span>, const void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">flags</span>,
       const struct sockaddr *<span class="docEmphItalicAlt">destaddr</span>, socklen_t
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">destlen</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphasis">flags</span>: 0, MSG_DONTROUTE, MSG_EOR, MSG_OOB</pre><BR>
</P>
<p class="docText">Returns: number of bytes sent if OK, 1 on error</p>
<p class="docText">Platforms: <tt>MSG_DONTWAIT</tt> flag on FreeBSD 5.2.1, Linux 2.4.22, Mac OS X 10.3 <tt>MSG_EOR</tt> flag not on Solaris 9</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec5.html#inta283">566</a>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setbuf</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, char *restrict <span class="docEmphItalicAlt">buf</span> );</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec4.html#inta284">136</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setegid</span>(gid_t <span class="docEmphItalicAlt">gid</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec11.html#inta285">241</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID595"></a><div class="v1"><a href="app01.html#PLID595">[View full width]</a></div><pre><span class="docEmphStrong">setenv</span>(const char *<span class="docEmphItalicAlt">name</span>, const char *<span class="docEmphItalicAlt">value</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">rewrite</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, nonzero on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec9.html#inta256">194</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">seteuid</span>(uid_t <span class="docEmphItalicAlt">uid</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec11.html#inta285">241</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setgid</span>(gid_t <span class="docEmphItalicAlt">gid</span>);</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec11.html#inta288">237</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setgrent</span>(void);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;grp.h&gt;</pre><BR>
</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec4.html#inta30">167</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setgroups</span>(int <span class="docEmphItalicAlt">ngroups</span>, const gid_t <span class="docEmphItalicAlt">grouplist</span>[]);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;grp.h&gt;    /* on Linux */
&lt;unistd.h&gt; /* on FreeBSD, Mac OS X, and Solaris */</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec5.html#inta105">168</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sethostent</span>(int <span class="docEmphItalicAlt">stayopen</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><BR>
</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta31">553</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setjmp</span>(jmp_buf <span class="docEmphItalicAlt">env</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;setjmp.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if called directly, nonzero if returning from a call to longjmp</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec10.html#inta154">197</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setlogmask</span>(int <span class="docEmphItalicAlt">maskpri</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;syslog.h&gt;</pre><br>
</P>
<p class="docText">Returns: previous log priority mask value</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch13lev1sec4.html#inta293">430</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setnetent</span>(int <span class="docEmphItalicAlt">stayopen</span>);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta32">554</a>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setpgid</span>(pid_t <span class="docEmphItalicAlt">pid</span>, pid_t <span class="docEmphItalicAlt">pgid</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec4.html#inta295">269</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setprotoent</span>(int <span class="docEmphItalicAlt">stayopen</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta32">554</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setpwent</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;pwd.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec2.html#inta34">164</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setregid</span>(gid_t <span class="docEmphItalicAlt">rgid</span>, gid_t <span class="docEmphItalicAlt">egid</span>);</pre><BR>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec11.html#inta298">240</a>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setreuid</span>(uid_t <span class="docEmphItalicAlt">ruid</span>, uid_t <span class="docEmphItalicAlt">euid</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec11.html#inta298">240</a>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setrlimit</span>(int <span class="docEmphItalicAlt">resource</span>, const struct rlimit *<span class="docEmphItalicAlt">rlptr</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/resource.h&gt;</pre><br>
Returns: 0 if OK, nonzero on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec11.html#inta127">202</a>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setservent</span>(int <span class="docEmphItalicAlt">stayopen</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;netdb.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec3.html#inta35">555</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setsid</span>(void);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
Returns: process group ID if OK, 1 on
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec5.html#inta302">271</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID629"></a><div class="v1"><a href="app01.html#PLID629">[View full width]</a></div><pre><span class="docEmphStrong">setsockopt</span>(int <span class="docEmphItalicAlt">sockfd</span>, int <span class="docEmphItalicAlt">level</span>, int <span class="docEmphItalicAlt">option</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> const void *<span class="docEmphItalicAlt">val</span>, socklen_t <span class="docEmphItalicAlt">len</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><br>
Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec6.html#inta303">579</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setspent</span>(void);</pre><br>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;shadow.h&gt;</pre><BR>
Platforms: Linux 2.4.22, Solaris 9</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec3.html#inta36">166</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">setuid</span>(uid_t <span class="docEmphItalicAlt">uid</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec11.html#inta288">237</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID635"></a><div class="v1"><a href="app01.html#PLID635">[View full width]</a></div><pre><span class="docEmphStrong">setvbuf</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, char *restrict <span class="docEmphItalicAlt">buf</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">mode</span>, size_t <span class="docEmphItalicAlt">size</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;
<span class="docEmphasis">mode</span>: _IOFBF, _IOLBF, _IONBF</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, nonzero on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec4.html#inta284">136</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">shmat</span>(int <span class="docEmphItalicAlt">shmid</span>, const void *<span class="docEmphItalicAlt">addr</span>, int <span class="docEmphItalicAlt">flag</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/shm.h&gt;<span class="docEmphItalicAlt">flag</span>: 0, SHM_RND, SHM_RDONLY</pre><br>
</P>
<p class="docText">Returns: pointer to shared memory segment if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec9.html#inta307">536</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">shmctl</span>(int <span class="docEmphItalicAlt">shmid</span>, int <span class="docEmphItalicAlt">cmd</span>, struct shmid_ds *<span class="docEmphItalicAlt">buf</span> );</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/shm.h&gt;
<span class="docEmphItalicAlt">cmd</span>: IPC_STAT, IPC_SET, IPC_RMID,
     SHM_LOCK, SHM_UNLOCK</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec9.html#inta308">535</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">shmdt</span>(void *<span class="docEmphItalicAlt">addr</span>);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/shm.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec9.html#inta309">536</a>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">shmget</span>(key_t <span class="docEmphItalicAlt">key</span>, int <span class="docEmphItalicAlt">size</span>, int <span class="docEmphItalicAlt">flag</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/shm.h&gt;
<span class="docEmphasis">flag</span>: 0, IPC_CREAT, IPC_EXCL</pre><BR>
</P>
<p class="docText">Returns: shared memory ID if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch15lev1sec9.html#inta310">534</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">shutdown</span>(int <span class="docEmphItalicAlt">sockfd</span>, int <span class="docEmphItalicAlt">how</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphasis">how</span>: SHUT_RD, SHUT_WR, SHUT_RDWR</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec2.html#inta311">548</a>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sig2str</span>(int <span class="docEmphItalicAlt">signo</span>, char *<span class="docEmphItalicAlt">str</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error Platforms: Solaris 9</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec21.html#inta312">353</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID649"></a><div class="v1"><a href="app01.html#PLID649">[View full width]</a></div><pre><span class="docEmphStrong">sigaction</span>(int <span class="docEmphItalicAlt">signo</span>, const struct sigaction
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">act</span>,
          struct sigaction *restrict <span class="docEmphItalicAlt">oact</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec14.html#inta313">324</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigaddset</span>(sigset_t *<span class="docEmphItalicAlt">set</span>, int <span class="docEmphItalicAlt">signo</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec11.html#inta314">319</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigdelset</span>(sigset_t *<span class="docEmphItalicAlt">set</span>, int <span class="docEmphItalicAlt">signo</span>);</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec11.html#inta314">319</a>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigemptyset</span>(sigset_t *<span class="docEmphItalicAlt">set</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec11.html#inta314">319</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigfillset</span>(sigset_t *<span class="docEmphItalicAlt">set</span>);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec11.html#inta314">319</a>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigismember</span>(const sigset_t *<span class="docEmphItalicAlt">set</span>, int <span class="docEmphItalicAlt">signo</span>);</pre><BR>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 1 if true, 0 if false, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec11.html#inta314">319</a>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">siglongjmp</span>(sigjmp_buf <span class="docEmphItalicAlt">env</span>, int <span class="docEmphItalicAlt">val</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;setjmp.h&gt;</pre><BR>
</p>
<p class="docText">This function never returns</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec15.html#inta319">330</a>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>(*<span class="docEmphStrong">signal</span>(int <span class="docEmphItalicAlt">signo</span>, void (*<span class="docEmphItalicAlt">func</span>)(int)))(int);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: previous disposition of signal if OK, <tt>SIG_ERR</tt> on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec3.html#inta320">298</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigpending</span>(sigset_t *<span class="docEmphItalicAlt">set</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec13.html#inta321">322</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigprocmask</span>(int <span class="docEmphItalicAlt">how</span>, const sigset_t *restrict <span class="docEmphItalicAlt">set</span>,
            sigset_t *restrict <span class="docEmphItalicAlt">oset</span>);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;
<span class="docEmphasis">how</span>: SIG_BLOCK, SIG_UNBLOCK, SIG_SETMASK</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec12.html#inta322">320</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigsetjmp</span>(sigjmp_buf <span class="docEmphItalicAlt">env</span>, int <span class="docEmphItalicAlt">savemask</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;setjmp.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if called directly, nonzero if returning from a call to <tt>siglongjmp</tt></P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec15.html#inta319">330</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sigsuspend</span>(const sigset_t *<span class="docEmphItalicAlt">sigmask</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</p>
<p class="docText">Returns: 1 with <tt>errno</tt> set to <tt>EINTR</tt></p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec16.html#inta324">334</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID673"></a><div class="v1"><a href="app01.html#PLID673">[View full width]</a></div><pre><span class="docEmphStrong">sigwait</span>(const sigset_t *restrict <span class="docEmphItalicAlt">set</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">signop</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, error number on failure</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch12lev1sec8.html#inta325">413</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>unsigned<br>int</pre><BR>
</P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sleep</span>(unsigned int <span class="docEmphItalicAlt">seconds</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 or number of unslept seconds</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec19.html#inta326">347</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID678"></a><div class="v1"><a href="app01.html#PLID678">[View full width]</a></div><pre><span class="docEmphStrong">snprintf</span>(char *restrict <span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">n</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">format</span>, ...);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p>
<p class="docText">Returns: number of characters stored in array if OK, negative value if encoding error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta70">149</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sockatmark</span>(int <span class="docEmphItalicAlt">sockfd</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><br>
</p>
<p class="docText">Returns: 1 if at mark, 0 if not at mark, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec7.html#inta328">582</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">socket</span>(int <span class="docEmphItalicAlt">domain</span>, int <span class="docEmphItalicAlt">type</span>, int <span class="docEmphItalicAlt">protocol</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;</pre><BR>
</P>
<p class="docText"><span class="docEmphItalicAlt">type</span>: <tt>SOCK_STREAM, SOCK_DGRAM, SOCK_SEQPACKET,</tt></P>
<p class="docText">Returns: file (socket) descriptor if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch16lev1sec2.html#inta329">546</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID684"></a><div class="v1"><a href="app01.html#PLID684">[View full width]</a></div><pre><span class="docEmphStrong">socketpair</span>(int <span class="docEmphItalicAlt">domain</span>, int <span class="docEmphItalicAlt">type</span>, int <span class="docEmphItalicAlt">protocol</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">sockfd</span>[2]);</pre><BR>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/socket.h&gt;
<span class="docEmphasis">type</span>: SOCK_STREAM, SOCK_DGRAM, SOCK_SEQPACKET,</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch17lev1sec3.html#inta330">594</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID686"></a><div class="v1"><a href="app01.html#PLID686">[View full width]</a></div><pre><span class="docEmphStrong">sprintf</span>(char *restrict <span class="docEmphItalicAlt">buf</span>, const char *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">format</span>, ...);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of characters stored in array if OK, negative value if encoding error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta70">149</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID688"></a><div class="v1"><a href="app01.html#PLID688">[View full width]</a></div><pre><span class="docEmphStrong">sscanf</span>(const char *restrict <span class="docEmphItalicAlt">buf</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">format</span>, ...);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of input items assigned, <tt>EOF</tt> if input error or end of file before any conversion</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID690"></a><div class="v1"><a href="app01.html#PLID690">[View full width]</a></div><pre><span class="docEmphStrong">stat</span>(const char *restrict <span class="docEmphItalicAlt">pathname</span>, struct stat
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">buf</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/stat.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec2.html#inta81">87</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">str2sig</span>(const char *<span class="docEmphItalicAlt">str</span>, int *<span class="docEmphItalicAlt">signop</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;signal.h&gt;</pre><br>
</P>
<p class="docText">Returns: 0 if OK, 1 on error Platforms: Solaris 9</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec21.html#inta312">353</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">strerror</span>(int <span class="docEmphasis">errnum</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;string.h&gt;</pre><br>
</P>
<p class="docText">Returns: pointer to message string</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch01lev1sec7.html#inta178">15</a>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>size_t</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID696"></a><div class="v1"><a href="app01.html#PLID696">[View full width]</a></div><pre><span class="docEmphStrong">strftime</span>(char *restrict <span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">maxsize</span>,
         const char *restrict <span class="docEmphItalicAlt">format</span>, const struct
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> tm *restrict <span class="docEmphItalicAlt">tmptr</span>);</pre><BR>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of characters stored in array if room, 0 otherwise</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec10.html#inta336">176</a>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">*strsignal</span>(int <span class="docEmphItalicAlt">signo</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;string.h&gt;</pre><BR>
</P>
<p class="docText">Returns: a pointer to a string describing the signal</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch10lev1sec21.html#inta337">352</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">symlink</span>(const char *<span class="docEmphItalicAlt">actualpath</span>, const char *<span class="docEmphasis">sympath</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec17.html#inta338">115</a>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sync</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec13.html#inta52">77</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>long</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">sysconf</span>(int <span class="docEmphItalicAlt">name</span>);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID705"></a><div class="v1"><a href="app01.html#PLID705">[View full width]</a></div><pre>&lt;unistd.h&gt;
<span class="docEmphItalicAlt">name</span>: _SC_ARG_MAX, _SC_ATEXIT_MAX, _SC_CHILD_MAX
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif">,_SC_CLK_TCK, _SC_COLL_WEIGHTS_MAX,
      _SC_HOST_NAME_MAX, _SC_IOV_MAX, _SC_JOB_CONTROL,
      _SC_LINE_MAX, _SC_LOGIN_NAME_MAX,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> _SC_NGROUPS_MAX,
      _SC_OPEN_MAX, _SC_PAGESIZE, _SC_PAGE_SIZE,
      _SC_READER_WRITER_LOCKS, _SC_RE_DUP_MAX,
      _SC_SAVED_IDS, _SC_SHELL, _SC_STREAM_MAX,
      _SC_SYMLOOP_MAX, _SC_TTY_NAME_MAX,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> _SC_TZNAME_MAX,
      _SC_VERSION, _SC_XOPEN_CRYPT, _SC_XOPEN_LEGACY,
      _SC_XOPEN_REALTIME, _SC_XOPEN_REALTIME_THREADS,
      _SC_XOPEN_VERSION</pre><BR>
</P>
<p class="docText">Returns: corresponding value if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch02lev1sec5.html#inta175">41</a>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">syslog</span>(int <span class="docEmphItalicAlt">priority</span>, char *<span class="docEmphItalicAlt">format</span>, ...);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;syslog.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch13lev1sec4.html#inta293">430</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">system</span>(const char *<span class="docEmphItalicAlt">cmdstring</span>);</pre><BR>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><BR>
</P>
<p class="docText">Returns: termination status of shell</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec13.html#inta342">246</a>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcdrain</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><BR>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec8.html#inta343">653</a>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcflow</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">action</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;
<span class="docEmphasis">action</span>: TCOOFF, TCOON, TCIOFF, TCION</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec8.html#inta343">653</a>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcflush</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">queue</span>);</pre><BR>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;
<span class="docEmphasis">queue</span>: TCIFLUSH, TCOFLUSH, TCIOFLUSH</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec8.html#inta343">653</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcgetattr</span>(int <span class="docEmphItalicAlt">filedes</span>, struct termios *<span class="docEmphItalicAlt">termptr</span>);</pre><BR>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec4.html#inta346">643</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcgetpgrp</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><BR>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: process group ID of foreground process group if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec7.html#inta347">273</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcgetsid</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><BR>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><BR>
</p>
<p class="docText">Returns: session leader's process group ID if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec7.html#inta348">274</a>
</p></TD></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcsendbreak</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">duration</span>);</pre><br>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec8.html#inta343">653</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID724"></a><div class="v1"><a href="app01.html#PLID724">[View full width]</a></div><pre><span class="docEmphStrong">tcsetattr</span>(int <span class="docEmphItalicAlt">filedes</span>, int <span class="docEmphItalicAlt">opt</span>, const struct
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> termios *<span class="docEmphItalicAlt">termptr</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;termios.h&gt;
<span class="docEmphasis">opt</span>: TCSANOW, TCSADRAIN, TCSAFLUSH</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec4.html#inta346">643</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">tcsetpgrp</span>(int <span class="docEmphItalicAlt">filedes</span>, pid_t <span class="docEmphItalicAlt">pgrpid</span>);</pre><br>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch09lev1sec7.html#inta347">273</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>long</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">telldir</span>(DIR *<span class="docEmphItalicAlt">dp</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;dirent.h&gt;</pre><BR>
</P>
<p class="docText">Returns: current location in directory associated with <span class="docEmphasis">dp</span></P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec21.html#inta173">120</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">tempnam</span>(const char *<span class="docEmphItalicAlt">directory</span>, const char *<span class="docEmphItalicAlt">prefix</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p>
<p class="docText">Returns: pointer to unique pathname</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec13.html#inta353">157</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>time_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">time</span>(time_t *<span class="docEmphItalicAlt">calptr</span>);</pre><br>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;time.h&gt;</pre><BR>
</p>
<p class="docText">Returns: value of time if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec10.html#inta354">173</a>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>clock_t</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">times</span>(struct tms *<span class="docEmphItalicAlt">buf</span>);</pre><BR>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/times.h&gt;</pre><BR>
</p>
<p class="docText">Returns: elapsed wall clock time in clock ticks if OK, 1 on error</P></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec16.html#inta355">257</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>FILE</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">tmpfile</span>(void);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</P>
<p class="docText">Returns: file pointer if OK, <tt>NULL</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec13.html#inta356">155</a>
</P></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">tmpnam</span>(char *<span class="docEmphItalicAlt">ptr</span>);</pre><br>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><BR>
</p>
<p class="docText">Returns: pointer to unique pathname</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec13.html#inta356">155</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">truncate</span>(const char *<span class="docEmphItalicAlt">pathname</span>, off_t <span class="docEmphItalicAlt">length</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</P></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec13.html#inta86">105</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>char</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre>*<span class="docEmphStrong">ttyname</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</p>
<p class="docText">Returns: pointer to pathname of terminal, <tt>NULL</tt> on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch18lev1sec9.html#inta148">655</a>
</p></TD></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>mode_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">umask</span>(mode_t <span class="docEmphItalicAlt">cmask</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/stat.h&gt;</pre><br>
</P>
<p class="docText">Returns: previous file mode creation mask</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec8.html#inta360">97</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">uname</span>(struct utsname *<span class="docEmphItalicAlt">name</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/utsname.h&gt;</pre><br>
</p>
<p class="docText">Returns: non-negative value if OK, 1 on error</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch06lev1sec9.html#inta361">171</a>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">ungetc</span>(int <span class="docEmphItalicAlt">c</span>, FILE *<span class="docEmphItalicAlt">fp</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: <span class="docEmphasis">c</span> if OK, <tt>EOF</tt> on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec6.html#inta59">141</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">unlink</span>(const char *<span class="docEmphItalicAlt">pathname</span>);</pre><br>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><BR>
</P>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec15.html#inta363">109</a>
</p></TD></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">unlockpt</span>(int <span class="docEmphItalicAlt">filedes</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 on success, 1 on error</p>
<p class="docText">Platforms: FreeBSD 5.2.1, Linux 2.4.22, Solaris 9</p></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch19lev1sec3.html#inta140">682</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">unsetenv</span>(const char *<span class="docEmphItalicAlt">name</span>);</pre><BR>
</p></TD></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdlib.h&gt;</pre><br>
</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch07lev1sec9.html#inta256">194</a>
</p></td></tr><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID756"></a><div class="v1"><a href="app01.html#PLID756">[View full width]</a></div><pre><span class="docEmphStrong">utime</span>(const char *<span class="docEmphItalicAlt">pathname</span>, const struct utimbuf
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">times</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;utime.h&gt;</pre><br>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch04lev1sec19.html#inta366">116</a>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID758"></a><div class="v1"><a href="app01.html#PLID758">[View full width]</a></div><pre><span class="docEmphStrong">vfprintf</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, const char *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">format</span>, va_list <span class="docEmphItalicAlt">arg</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of characters output if OK, negative value if output error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID760"></a><div class="v1"><a href="app01.html#PLID760">[View full width]</a></div><pre><span class="docEmphStrong">vfscanf</span>(FILE *restrict <span class="docEmphItalicAlt">fp</span>, const char *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">format</span>, va_list <span class="docEmphItalicAlt">arg</span>);</pre><br>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: number of input items assigned, <tt>EOF</tt> if input error or end of file before any conversion</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</p></td></tr><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">vprintf</span>(const char *restrict <span class="docEmphItalicAlt">format</span>, va_list <span class="docEmphItalicAlt">arg</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><BR>
</P>
<p class="docText">Returns: number of characters output if OK, negative value if output error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</p></TD></TR><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">vscanf</span>(const char *restrict <span class="docEmphItalicAlt">format</span>, va_list <span class="docEmphItalicAlt">arg</span>);</pre><br>
</P></td></TR><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: number of input items assigned, <tt>EOF</tt> if input error or end of file before any conversion</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID766"></a><div class="v1"><a href="app01.html#PLID766">[View full width]</a></div><pre><span class="docEmphStrong">vsnprintf</span>(char *restrict <span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">n</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphItalicAlt">format</span>,
          va_list <span class="docEmphItalicAlt">arg</span>);</pre><br>
</P></TD></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of characters stored in array if OK, negative value if encoding error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</P></TD></tr><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID768"></a><div class="v1"><a href="app01.html#PLID768">[View full width]</a></div><pre><span class="docEmphStrong">vsprintf</span>(char *restrict <span class="docEmphItalicAlt">buf</span>, const char *restrict
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">format</span>, va_list <span class="docEmphItalicAlt">arg</span>);</pre><br>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><br>
</p>
<p class="docText">Returns: number of characters stored in array if OK, negative value if encoding error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID770"></a><div class="v1"><a href="app01.html#PLID770">[View full width]</a></div><pre><span class="docEmphStrong">vsscanf</span>(const char *restrict <span class="docEmphItalicAlt">buf</span>, const char
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *restrict <span class="docEmphasis">format</span>,
        va_list <span class="docEmphItalicAlt">arg</span>);</pre><BR>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;stdarg.h&gt;
&lt;stdio.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of input items assigned, <tt>EOF</tt> if input error or end of file before any conversion</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch05lev1sec11.html#inta368">151</a>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>void</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID772"></a><div class="v1"><a href="app01.html#PLID772">[View full width]</a></div><pre><span class="docEmphStrong">vsyslog</span> (int <span class="docEmphasis">priority</span>, const char *<span class="docEmphItalicAlt">format</span>, va_list
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">arg</span>);</pre><br>
</p></td></TR><tr><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;syslog.h&gt;
&lt;stdarg.h&gt;</pre><br>
</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch13lev1sec4.html#inta374">432</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">wait</span>(int *<span class="docEmphItalicAlt">statloc</span>);</pre><br>
</p></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/wait.h&gt;</pre><BR>
</P>
<p class="docText">Returns: process ID if OK, 0, or 1 on error</P></td><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec6.html#inta375">220</a>
</p></TD></TR><TR><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>int</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID776"></a><div class="v1"><a href="app01.html#PLID776">[View full width]</a></div><pre><span class="docEmphStrong">waitid</span>(idtype_t <span class="docEmphItalicAlt">idtype</span>, id_t <span class="docEmphItalicAlt">id</span>, siginfo_t *<span class="docEmphItalicAlt">infop</span>,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> int <span class="docEmphItalicAlt">options</span>);</pre><BR>
</P></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top">&nbsp;</TD><td class="docTableCell" align="left" valign="top"><p class="docText">
<a name="PLID777"></a><div class="v1"><a href="app01.html#PLID777">[View full width]</a></div><pre>&lt;sys/wait.h&gt;
<span class="docEmphItalicAlt">idtype</span>: P_PID, P_PGID, P_ALL
<span class="docEmphItalicAlt">options</span>: WCONTINUED, WEXITED, WNOHANG, WNOWAIT,
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> WSTOPPED</pre><BR>
</p>
<p class="docText">Returns: 0 if OK, 1 on error</p>
<p class="docText">Platforms: Solaris 9</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec6.html#inta375">220</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">waitpid</span>(pid_t <span class="docEmphItalicAlt">pid</span>, int *<span class="docEmphItalicAlt">statloc</span>, int <span class="docEmphItalicAlt">options</span>);</pre><br>
</p></td></tr><TR><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;sys/wait.h&gt;
<span class="docEmphasis">options</span>: 0, WCONTINUED, WNOHANG, WUNTRACED</pre><br>
</P>
<p class="docText">Returns: process ID if OK, 0, or 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec6.html#inta375">220</a>
</P></td></TR><TR><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></TD><TD class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID780"></a><div class="v1"><a href="app01.html#PLID780">[View full width]</a></div><pre><span class="docEmphStrong">wait3</span>(int *<span class="docEmphItalicAlt">statloc</span>, int <span class="docEmphItalicAlt">options</span>, struct rusage
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> *<span class="docEmphItalicAlt">rusage</span>);</pre><br>
</P></TD></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;sys/types.h&gt;
&lt;sys/wait.h&gt;
&lt;sys/time.h&gt;
&lt;sys/resource.h&gt;
<span class="docEmphasis">options</span>: 0, WNOHANG, WUNTRACED</pre><br>
</P>
<p class="docText">Returns: process ID if OK, 0, or 1 on error</p></td><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec8.html#inta378">227</a></p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>pid_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID782"></a><div class="v1"><a href="app01.html#PLID782">[View full width]</a></div><pre><span class="docEmphStrong">wait4</span>(pid_t <span class="docEmphItalicAlt">pid</span>, int *<span class="docEmphItalicAlt">statloc</span>, int <span class="docEmphItalicAlt">options</span>, struct
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> rusage *<span class="docEmphItalicAlt">rusage</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>
&lt;sys/types.h&gt;
&lt;sys/wait.h&gt;
&lt;sys/time.h&gt;
&lt;sys/resource.h&gt;
<span class="docEmphItalicAlt">options</span>: 0, WNOHANG, WUNTRACED</pre><BR>
</P>
<p class="docText">Returns: process ID if OK, 0, or 1 on error</p></TD><TD class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch08lev1sec8.html#inta378">227</a>
</P></td></TR><tr><TD class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></P></TD><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<pre><span class="docEmphStrong">write</span>(int <span class="docEmphItalicAlt">filedes</span>, const void *<span class="docEmphItalicAlt">buf</span>, size_t <span class="docEmphItalicAlt">nbytes</span>);</pre><BR>
</P></td></TR><TR><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</td><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;unistd.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of bytes written if OK, 1 on error</p></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch03lev1sec8.html#inta380">68</a>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top"><p class="docText"><tt>ssize_t</tt></p></td><td class="docTableCell" align="left" valign="top" colspan="3"><p class="docText">
<a name="PLID786"></a><div class="v1"><a href="app01.html#PLID786">[View full width]</a></div><pre><span class="docEmphStrong">writev</span>(int <span class="docEmphItalicAlt">filedes</span>, const struct iovec *<span class="docEmphItalicAlt">iov</span>, int
<img border="0" width="14" height="9" alt="" align="left" src="images/ccc.gif"> <span class="docEmphItalicAlt">iovcnt</span>);</pre><br>
</p></td></tr><tr><td class="docTableCell" align="left" valign="top">&nbsp;</td><td class="docTableCell" align="left" valign="top">&nbsp;</TD><TD class="docTableCell" align="left" valign="top"><p class="docText">
<pre>&lt;sys/uio.h&gt;</pre><br>
</P>
<p class="docText">Returns: number of bytes written if OK, 1 on error</P></TD><td class="docTableCell" align="left" valign="top"><p class="docText">p. <a class="docLink" href="ch14lev1sec7.html#inta265">483</a>
</P></TD></TR></table></p><BR>

<a href="17021535.html"><img src="images/pixel.gif" alt="" width="1" height="1" border="0"></a><ul></UL></TD></TR></table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr><td><div STYLE="MARGIN-LEFT: 0.15in;"><a href="toc.html"><img src="images/team.gif" width="60" height="17" border="0" align="absmiddle"  alt="Team BBL"></a></div></td>
<td align="right"><div STYLE="MARGIN-LEFT: 0.15in;">
<a href=ch21lev1sec7.html><img src="images/prev.gif" width="60" height="17" border="0" align="absmiddle" alt="Previous Page"></a>
<a href=app02.html><img src="images/next.gif" width="60" height="17" border="0" align="absmiddle" alt="Next Page"></a>
</div></td></tr></table>
</body></html><br>
<table width="100%" cellspacing="0" cellpadding="0"
style="margin-top: 0pt; border-collapse: collapse;"> 
<tr> <td align="right" style="background-color=white; border-top: 1px solid gray;"> 
<a href="http://www.zipghost.com/" target="_blank" style="font-family: Tahoma, Verdana;
 font-size: 11px; text-decoration: none;">The CHM file was converted to HTM by Trial version of <b>ChmD<!--10-->ecompiler</b>.</a>
</TD>
</TR><tr>
<td align="right" style="background-color=white; "> 
<a href="http://www.etextwizard.com/download/cd/cdsetup.exe" target="_blank" style="font-family: Tahoma, Verdana;
 font-size: 11px; text-decoration: none;">Download <b>ChmDec<!--10-->ompiler</b> at: http://www.zipghost.com</a>
</TD></tr></table>
